fix ci test
This commit is contained in:
parent
dfd5a8e2de
commit
a0c683aeb6
2 changed files with 3 additions and 4 deletions
|
|
@ -16,7 +16,7 @@ func NewOnboardCommand() *cobra.Command {
|
||||||
cmd := &cobra.Command{
|
cmd := &cobra.Command{
|
||||||
Use: "onboard",
|
Use: "onboard",
|
||||||
Aliases: []string{"o"},
|
Aliases: []string{"o"},
|
||||||
Short: "Initialize picoclaw configuration, workspace, and channel accounts",
|
Short: "Initialize picoclaw configuration and workspace",
|
||||||
// Run without subcommands → original onboard flow
|
// Run without subcommands → original onboard flow
|
||||||
Run: func(cmd *cobra.Command, args []string) {
|
Run: func(cmd *cobra.Command, args []string) {
|
||||||
if len(args) == 0 {
|
if len(args) == 0 {
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,7 @@ func TestNewOnboardCommand(t *testing.T) {
|
||||||
require.NotNil(t, cmd)
|
require.NotNil(t, cmd)
|
||||||
|
|
||||||
assert.Equal(t, "onboard", cmd.Use)
|
assert.Equal(t, "onboard", cmd.Use)
|
||||||
assert.Equal(t, "Initialize picoclaw configuration, workspace, and channel accounts", cmd.Short)
|
assert.Equal(t, "Initialize picoclaw configuration and workspace", cmd.Short)
|
||||||
|
|
||||||
assert.Len(t, cmd.Aliases, 1)
|
assert.Len(t, cmd.Aliases, 1)
|
||||||
assert.True(t, cmd.HasAlias("o"))
|
assert.True(t, cmd.HasAlias("o"))
|
||||||
|
|
@ -28,6 +28,5 @@ func TestNewOnboardCommand(t *testing.T) {
|
||||||
encFlag := cmd.Flags().Lookup("enc")
|
encFlag := cmd.Flags().Lookup("enc")
|
||||||
require.NotNil(t, encFlag, "expected --enc flag to be registered")
|
require.NotNil(t, encFlag, "expected --enc flag to be registered")
|
||||||
assert.Equal(t, "false", encFlag.DefValue, "--enc should default to false")
|
assert.Equal(t, "false", encFlag.DefValue, "--enc should default to false")
|
||||||
assert.True(t, cmd.HasSubCommands())
|
assert.False(t, cmd.HasSubCommands())
|
||||||
assert.NotNil(t, cmd.Commands())
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue