diff --git a/tests/integration/diff_test.go b/tests/integration/diff_test.go index b9d3a7184..4785ce75a 100644 --- a/tests/integration/diff_test.go +++ b/tests/integration/diff_test.go @@ -10,7 +10,8 @@ import ( ) var ( - expectedOutputMasked = `updating service svc1 { + expectedOutputMasked = `Warning: 'deck diff' is DEPRECATED and will be removed in a future version. Use 'deck gateway diff' instead. +updating service svc1 { "connect_timeout": 60000, "enabled": true, "host": "[masked]", @@ -37,7 +38,8 @@ Summary: Deleted: 0 ` - expectedOutputUnMasked = `updating service svc1 { + expectedOutputUnMasked = `Warning: 'deck diff' is DEPRECATED and will be removed in a future version. Use 'deck gateway diff' instead. +updating service svc1 { "connect_timeout": 60000, "enabled": true, "host": "mockbin.org", @@ -68,7 +70,8 @@ Summary: "DECK_FOO": "foo_test", // unused, partial match } - expectedOutputUnMaskedJSON = `{ + expectedOutputUnMaskedJSON = `Warning: 'deck diff' is DEPRECATED and will be removed in a future version. Use 'deck gateway diff' instead. +{ "changes": { "creating": [ { @@ -164,7 +167,8 @@ Summary: ` - expectedOutputMaskedJSON = `{ + expectedOutputMaskedJSON = `Warning: 'deck diff' is DEPRECATED and will be removed in a future version. Use 'deck gateway diff' instead. +{ "changes": { "creating": [ { @@ -264,7 +268,8 @@ Summary: ` - expectedOutputUnMaskedJSON30x = `{ + expectedOutputUnMaskedJSON30x = `Warning: 'deck diff' is DEPRECATED and will be removed in a future version. Use 'deck gateway diff' instead. +{ "changes": { "creating": [ { @@ -358,7 +363,8 @@ Summary: ` - expectedOutputMaskedJSON30x = `{ + expectedOutputMaskedJSON30x = `Warning: 'deck diff' is DEPRECATED and will be removed in a future version. Use 'deck gateway diff' instead. +{ "changes": { "creating": [ { diff --git a/tests/integration/test_utils.go b/tests/integration/test_utils.go index a72829a14..721247174 100644 --- a/tests/integration/test_utils.go +++ b/tests/integration/test_utils.go @@ -215,7 +215,7 @@ func testKongState(t *testing.T, client *kong.Client, isKonnect bool, func reset(t *testing.T, opts ...string) { deckCmd := cmd.NewRootCmd() - args := []string{"gateway", "reset", "--force"} + args := []string{"reset", "--force"} if len(opts) > 0 { args = append(args, opts...) } @@ -248,7 +248,7 @@ func setup(t *testing.T) { func sync(kongFile string, opts ...string) error { deckCmd := cmd.NewRootCmd() - args := []string{"gateway", "sync", kongFile} + args := []string{"sync", "-s", kongFile} if len(opts) > 0 { args = append(args, opts...) } @@ -258,7 +258,7 @@ func sync(kongFile string, opts ...string) error { func diff(kongFile string, opts ...string) (string, error) { deckCmd := cmd.NewRootCmd() - args := []string{"gateway", "diff", kongFile} + args := []string{"diff", "-s", kongFile} if len(opts) > 0 { args = append(args, opts...) } @@ -280,7 +280,7 @@ func diff(kongFile string, opts ...string) (string, error) { func dump(opts ...string) (string, error) { deckCmd := cmd.NewRootCmd() - args := []string{"gateway", "dump", "-o=kong"} + args := []string{"dump"} if len(opts) > 0 { args = append(args, opts...) } @@ -324,7 +324,7 @@ func lint(opts ...string) (string, error) { func ping(opts ...string) error { deckCmd := cmd.NewRootCmd() - args := []string{"gateway", "ping"} + args := []string{"ping"} if len(opts) > 0 { args = append(args, opts...) }