main: show "success" message with output dir when build finishes
This commit adds a "success" message that also contains the output dir when the build finishes. Thanks to SimonS for suggesting this!
This commit is contained in:
parent
3eecad6b30
commit
06e73caec1
2 changed files with 8 additions and 1 deletions
|
|
@ -325,6 +325,10 @@ func TestBuildIntegrationHappy(t *testing.T) {
|
|||
restore := main.MockNewRepoRegistry(testrepos.New)
|
||||
defer restore()
|
||||
|
||||
var fakeStdout bytes.Buffer
|
||||
restore = main.MockOsStdout(&fakeStdout)
|
||||
defer restore()
|
||||
|
||||
tmpdir := t.TempDir()
|
||||
restore = main.MockOsArgs([]string{
|
||||
"build",
|
||||
|
|
@ -342,6 +346,8 @@ func TestBuildIntegrationHappy(t *testing.T) {
|
|||
err := main.Run()
|
||||
assert.NoError(t, err)
|
||||
|
||||
assert.Contains(t, fakeStdout.String(), `Image build successful, result in "centos-9-qcow2-x86_64"`+"\n")
|
||||
|
||||
// ensure osbuild was run exactly one
|
||||
require.Equal(t, 1, len(fakeOsbuildCmd.Calls()))
|
||||
osbuildCall := fakeOsbuildCmd.Calls()[0]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue