27 lines
557 B
Go
27 lines
557 B
Go
|
package commands
|
|||
|
|
|||
|
import (
|
|||
|
"github.com/photoprism/photoprism/internal/config"
|
|||
|
"github.com/photoprism/photoprism/pkg/capture"
|
|||
|
"github.com/stretchr/testify/assert"
|
|||
|
"testing"
|
|||
|
)
|
|||
|
|
|||
|
func TestShowConfigOptionsCommand(t *testing.T) {
|
|||
|
var err error
|
|||
|
|
|||
|
ctx := config.CliTestContext()
|
|||
|
|
|||
|
output := capture.Output(func() {
|
|||
|
err = ShowConfigOptionsCommand.Run(ctx)
|
|||
|
})
|
|||
|
|
|||
|
if err != nil {
|
|||
|
t.Fatal(err)
|
|||
|
}
|
|||
|
|
|||
|
assert.Contains(t, output, "PHOTOPRISM_IMPORT_PATH")
|
|||
|
assert.Contains(t, output, "--sidecar-path")
|
|||
|
assert.Contains(t, output, "sidecar `PATH` *optional*")
|
|||
|
}
|