mirror of
https://github.com/photoprism/photoprism.git
synced 2025-12-12 00:34:13 +01:00
Commands: Refactor "show config-options" and "show config-yaml" tests
Signed-off-by: Michael Mayer <michael@photoprism.app>
This commit is contained in:
@@ -3,15 +3,19 @@ package commands
|
||||
import (
|
||||
"testing"
|
||||
|
||||
"github.com/photoprism/photoprism/pkg/capture"
|
||||
"github.com/stretchr/testify/assert"
|
||||
)
|
||||
|
||||
func TestShowConfigOptionsCommand(t *testing.T) {
|
||||
var err error
|
||||
|
||||
ctx := NewTestContext([]string{})
|
||||
ctx := NewTestContext([]string{"config-options", "--md"})
|
||||
|
||||
err = ShowConfigOptionsCommand.Run(ctx)
|
||||
output := capture.Stdout(func() {
|
||||
err = ShowConfigOptionsCommand.Run(ctx)
|
||||
})
|
||||
|
||||
assert.NoError(t, err)
|
||||
assert.Contains(t, output, "PHOTOPRISM_IMPORT_PATH")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user