Skip to content

Commit

Permalink
fix update ql output
Browse files Browse the repository at this point in the history
  • Loading branch information
pmenglund committed Nov 6, 2023
1 parent b0425da commit 19c5e09
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion cmd/query_lambda.go
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ func newUpdateQueryLambdaCmd() *cobra.Command {
if err != nil {
return err
}
_, _ = fmt.Fprintf(cmd.OutOrStdout(), "updated query lambda %s.%s:%s",
_, _ = fmt.Fprintf(cmd.OutOrStdout(), "updated query lambda %s.%s:%s\n",
ql.GetWorkspace(), ql.GetName(), ql.GetVersion())

if err = waitUntilQLActive(rs, cmd, ws, args[0], ql.GetVersion()); err != nil {
Expand Down
8 changes: 4 additions & 4 deletions cmd/query_lambda_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@ func (s *QueryLambdaSuite) Test_0_Create() {
c := cmd.NewRootCmd("test")
out := test.WrapAndExecute(s.T(), c, "create", "ql", "--sql", "testdata/query_lambda.sql", "--wait", s.name)

re := regexp.MustCompile(`created query lambda commons\.\w+:(\w+)`)
re := regexp.MustCompile(`created query lambda commons\.\w+:(\w+)\s`)
m := re.FindStringSubmatch(out.String())
s.NotNil(m)
s.Require().NotNil(m, "no regexp match")
s.version = m[1]
}

Expand Down Expand Up @@ -59,9 +59,9 @@ func (s *QueryLambdaSuite) Test_4_Update() {
c := cmd.NewRootCmd("test")
out := test.WrapAndExecute(s.T(), c, "update", "ql", "--sql", "testdata/query_lambda_updated.sql", "--wait", s.name)

re := regexp.MustCompile(`updated query lambda commons\.\w+:(\w+)`)
re := regexp.MustCompile(`updated query lambda commons\.\w+:(\w+)\s`)
m := re.FindStringSubmatch(out.String())
s.NotNil(m)
s.Require().NotNil(m, "no regexp match")
s.version = m[1]
}

Expand Down

0 comments on commit 19c5e09

Please sign in to comment.