Expose native configuration inspection scopes
This commit is contained in:
@@ -10,7 +10,7 @@ func TestPipelineMaterializationPreservesFinalValuesWithoutResolvingCredentialsA
|
||||
const name = "NARRATIO_SNAPSHOT_TEST_KEY"
|
||||
const secret = "synthetic-snapshot-secret"
|
||||
t.Setenv(name, secret)
|
||||
path := writePipelineFixture(t, t.TempDir(), "pipeline.yml", `audita:
|
||||
path := writePipelineFixture(t, t.TempDir(), "pipeline.yml", testTranscriptionConfig+`audita:
|
||||
credentials: [NARRATIO_SNAPSHOT_TEST_KEY]
|
||||
scriptorium:
|
||||
artifact_families:
|
||||
@@ -21,9 +21,7 @@ scriptorium:
|
||||
artifacts:
|
||||
recap:
|
||||
vars:
|
||||
exact: 9007199254740993
|
||||
nothing: null
|
||||
empty: []
|
||||
title: synthetic-title
|
||||
`)
|
||||
cfg, err := LoadPipeline(path)
|
||||
if err != nil {
|
||||
@@ -39,7 +37,7 @@ scriptorium:
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
for _, expected := range []string{name, "9007199254740993", "nothing: null", "empty: []", "character_notes:", "artifact_families:"} {
|
||||
for _, expected := range []string{name, "synthetic-title", "character_notes:", "artifact_families:"} {
|
||||
if !strings.Contains(string(data), expected) {
|
||||
t.Fatalf("snapshot missing %q: %s", expected, data)
|
||||
}
|
||||
@@ -51,8 +49,8 @@ scriptorium:
|
||||
|
||||
func TestPipelineMaterializationKeepsEmptyCredentialListDistinctFromNull(t *testing.T) {
|
||||
dir := t.TempDir()
|
||||
nullPath := writePipelineFixture(t, dir, "null.yml", "audita: {credentials: null}\n")
|
||||
emptyPath := writePipelineFixture(t, dir, "empty.yml", "audita: {credentials: []}\n")
|
||||
nullPath := writePipelineFixture(t, dir, "null.yml", testTranscriptionConfig+"audita: {credentials: null}\n")
|
||||
emptyPath := writePipelineFixture(t, dir, "empty.yml", testTranscriptionConfig+"audita: {credentials: []}\n")
|
||||
nullConfig, err := LoadPipeline(nullPath)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
|
||||
Reference in New Issue
Block a user