Expose native configuration inspection scopes
This commit is contained in:
@@ -3,7 +3,6 @@ package app
|
||||
import (
|
||||
"bytes"
|
||||
"context"
|
||||
"io"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"reflect"
|
||||
@@ -253,19 +252,8 @@ func TestAssembledSplitBundleCommandsUseOneEffectiveFamilyConfiguration(t *testi
|
||||
t.Fatalf("example workspace stat = %v, want absent", err)
|
||||
}
|
||||
|
||||
var validated bytes.Buffer
|
||||
if err := ConfigValidate(context.Background(), []string{"--config", pipelinePath, "--campaign-file", campaignPath}, &validated); err != nil {
|
||||
t.Fatalf("validate production base: %v", err)
|
||||
}
|
||||
if !strings.Contains(validated.String(), "overlay=none") {
|
||||
t.Fatalf("validate output = %q, want production base", validated.String())
|
||||
}
|
||||
for _, command := range []func(context.Context, []string, io.Writer) error{ConfigShow, ConfigSources} {
|
||||
if err := command(context.Background(), []string{
|
||||
"--config", pipelinePath, "--campaign-file", campaignPath, "--overlay", "testing",
|
||||
}, io.Discard); err != nil {
|
||||
t.Fatalf("testing inspection command %T: %v", command, err)
|
||||
}
|
||||
for _, operation := range []string{"validate", "show", "sources"} {
|
||||
nativeInspectionForTest(t, []string{"config", operation, "--config", pipelinePath, "--overlay", "testing"})
|
||||
}
|
||||
var diff bytes.Buffer
|
||||
if err := ConfigDiff(context.Background(), []string{
|
||||
|
||||
Reference in New Issue
Block a user