diff --git a/cmd/summer/main.go b/cmd/summer/main.go index af422b88..c4121e03 100644 --- a/cmd/summer/main.go +++ b/cmd/summer/main.go @@ -155,7 +155,7 @@ overwritten.`, {Command: "make:model acme.blog Post", Description: "A Post model and its create-table migration"}, {Command: "make:model Post --no-migration", Description: "Inside plugins/acme/blog: only the model"}, }, - Args: makeArtifactArgs(), + Args: makeArtifactArgs(), Flags: []bonfire.Flag{{ Name: "no-migration", Description: "Omit the create-table migration", @@ -192,7 +192,7 @@ to apply it.`, {Command: "make:migration acme.blog AddSlugToPosts", Description: "An empty migration in acme.blog"}, {Command: "make:migration AddSlugToPosts", Description: "The same from inside plugins/acme/blog"}, }, - Args: makeArtifactArgs(), + Args: makeArtifactArgs(), Run: func(ctx context.Context, in bonfire.Input, out bonfire.Output) error { dir, err := os.Getwd() if err != nil { @@ -226,7 +226,7 @@ from the plugin's Commands by hand.`, {Command: "make:command acme.blog Publish", Description: "A blog:publish command in acme.blog"}, {Command: "make:command Publish", Description: "The same from inside plugins/acme/blog"}, }, - Args: makeArtifactArgs(), + Args: makeArtifactArgs(), Run: func(ctx context.Context, in bonfire.Input, out bonfire.Output) error { dir, err := os.Getwd() if err != nil { @@ -257,7 +257,7 @@ conga.Manager.Dispatch; queue:work or serve runs it.`, {Command: "make:job acme.blog SendDigest", Description: "A SendDigest job in acme.blog"}, {Command: "make:job SendDigest", Description: "The same from inside plugins/acme/blog"}, }, - Args: makeArtifactArgs(), + Args: makeArtifactArgs(), Run: func(ctx context.Context, in bonfire.Input, out bonfire.Output) error { dir, err := os.Getwd() if err != nil { diff --git a/cmd/summer/runtime.go b/cmd/summer/runtime.go index ec410930..cfad3627 100644 --- a/cmd/summer/runtime.go +++ b/cmd/summer/runtime.go @@ -27,7 +27,7 @@ func delegateCommands() []bonfire.Command { ex := func(cmd, desc string) bonfire.Example { return bonfire.Example{Command: cmd, Description: desc} } rows := []struct { name, description, hint string - examples []bonfire.Example + examples []bonfire.Example }{ {"migrate", "Run plugin migrations in the app binary", "--pretend, --force", []bonfire.Example{ ex("migrate", "Apply every pending migration"), diff --git a/cmd/summer/runtime_test.go b/cmd/summer/runtime_test.go index e4f5334a..0e7dd3db 100644 --- a/cmd/summer/runtime_test.go +++ b/cmd/summer/runtime_test.go @@ -81,11 +81,11 @@ func TestDelegateCommandsPassArgs(t *testing.T) { func TestDelegateCommandsHelp(t *testing.T) { hints := map[string][]string{ - "migrate:rollback": {"--plugin"}, - "queue:work": {"--queue"}, - "schedule:run": {"--once"}, - "serve": {"--addr"}, - "admin:create": {"--email", "--superuser"}, + "migrate:rollback": {"--plugin"}, + "queue:work": {"--queue"}, + "schedule:run": {"--once"}, + "serve": {"--addr"}, + "admin:create": {"--email", "--superuser"}, "admin:token:create": {"--name", "--scope", "--expires"}, } cmds := delegateCommands() diff --git a/modules/bonfire/output.go b/modules/bonfire/output.go index 8c639d10..4ca0d566 100644 --- a/modules/bonfire/output.go +++ b/modules/bonfire/output.go @@ -50,7 +50,7 @@ type console struct { // errStream is the stream the root's error block goes to, when the // console belongs to a root (ErrWriter); nil means err. errStream io.Writer - lookup func(string) string + lookup func(string) string // tty is true when stdout is a terminal; it picks animated widgets // and boxed tables. tty bool diff --git a/modules/cabana/account_tokens_test.go b/modules/cabana/account_tokens_test.go index db4d037a..10dbed00 100644 --- a/modules/cabana/account_tokens_test.go +++ b/modules/cabana/account_tokens_test.go @@ -155,8 +155,8 @@ func TestAccountTokens(t *testing.T) { // 422 rules with server message text. cases := []struct { - name string - body map[string]any + name string + body map[string]any field string msg string }{ diff --git a/modules/cabana/field_trigger_smoke_test.go b/modules/cabana/field_trigger_smoke_test.go index 9858372a..28c1982c 100644 --- a/modules/cabana/field_trigger_smoke_test.go +++ b/modules/cabana/field_trigger_smoke_test.go @@ -48,7 +48,9 @@ func TestFieldTriggerSmoke(t *testing.T) { } }) - trig := func(body string) string { return base + " notes:\n type: textarea\n trigger:\n" + body } + trig := func(body string) string { + return base + " notes:\n type: textarea\n trigger:\n" + body + } for _, tc := range []struct{ name, fields, want string }{ {"unknown action", trig(" action: show\n field: is_admin\n condition: checked\n"), "action show is not supported"}, {"unknown condition", trig(" action: hide\n field: is_admin\n condition: value[1]\n"), "condition value[1] is not supported"}, diff --git a/modules/cabana/token_postgres_smoke_test.go b/modules/cabana/token_postgres_smoke_test.go index 87f44fb6..77dd411c 100644 --- a/modules/cabana/token_postgres_smoke_test.go +++ b/modules/cabana/token_postgres_smoke_test.go @@ -28,9 +28,9 @@ type tokenDemoWidget struct { Name string `gorm:"column:name"` } -func (tokenDemoWidget) TableName() string { return "cabana_token_demo_widgets" } -func (tokenDemoWidget) Fillable() []string { return []string{"name"} } -func (tokenDemoWidget) Rules() map[string]string { return map[string]string{} } +func (tokenDemoWidget) TableName() string { return "cabana_token_demo_widgets" } +func (tokenDemoWidget) Fillable() []string { return []string{"name"} } +func (tokenDemoWidget) Rules() map[string]string { return map[string]string{} } type tokenDemoPlugin struct{ fsys fs.FS } diff --git a/modules/cabana/token_routes_test.go b/modules/cabana/token_routes_test.go index 61b5f95a..952ee1c4 100644 --- a/modules/cabana/token_routes_test.go +++ b/modules/cabana/token_routes_test.go @@ -28,83 +28,83 @@ const ( // tokenRouteClasses maps every phase09Routes key to its personal-token class. // Adding a route without a class fails TestTokenRouteGates. var tokenRouteClasses = map[string]tokenRouteClass{ - "POST /auth/login": classPublic, + "POST /auth/login": classPublic, "POST /auth/refresh": classInteractive, // public to JWT, but interactive-only for tokens - "GET /lang": classPublic, - "POST /auth/logout": classInteractive, - "GET /auth/me": classOpenAnyToken, + "GET /lang": classPublic, + "POST /auth/logout": classInteractive, + "GET /auth/me": classOpenAnyToken, - "PUT /account": classInteractive, - "GET /account/preferences": classInteractive, - "PUT /account/preferences": classInteractive, - "POST /account/avatar": classInteractive, - "DELETE /account/avatar": classInteractive, - "GET /account/tokens": classInteractive, - "POST /account/tokens": classInteractive, - "GET /account/tokens/scopes": classInteractive, - "DELETE /account/tokens/{id}": classInteractive, - "GET /account/contributions": classInteractive, + "PUT /account": classInteractive, + "GET /account/preferences": classInteractive, + "PUT /account/preferences": classInteractive, + "POST /account/avatar": classInteractive, + "DELETE /account/avatar": classInteractive, + "GET /account/tokens": classInteractive, + "POST /account/tokens": classInteractive, + "GET /account/tokens/scopes": classInteractive, + "DELETE /account/tokens/{id}": classInteractive, + "GET /account/contributions": classInteractive, "POST /account/contributions/{name}/actions/{action}": classInteractive, - "GET /navigation": classAllowsNav, - "GET /field-types": classExplicitGate, - "GET /settings": classAllowsSettings, - "GET /plugins": classAllowsProtect, - "GET /plugins/marketplace": classAllowsProtect, - "GET /settings/{code}/schema": classAllowsSettings, - "GET /settings/{code}": classAllowsSettings, - "PUT /settings/{code}": classAllowsSettings, - "POST /markdown/preview": classExplicitGate, + "GET /navigation": classAllowsNav, + "GET /field-types": classExplicitGate, + "GET /settings": classAllowsSettings, + "GET /plugins": classAllowsProtect, + "GET /plugins/marketplace": classAllowsProtect, + "GET /settings/{code}/schema": classAllowsSettings, + "GET /settings/{code}": classAllowsSettings, + "PUT /settings/{code}": classAllowsSettings, + "POST /markdown/preview": classExplicitGate, - "GET /{vendor}/{plugin}/{controller}/schema/list": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/schema/form": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/schema/relation/{name}": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/partials/{name}": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/fields/{field}/options": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/fields/{field}/dependent-options": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/filters/{scope}/options": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/bulk-delete": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/reorder": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/reorder": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/singleton": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/bulk/{action}": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/widgets/{field}": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/toolbar/{action}": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/{id}": classAllowsProtect, - "PUT /{vendor}/{plugin}/{controller}/{id}": classAllowsProtect, - "DELETE /{vendor}/{plugin}/{controller}/{id}": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/{id}/actions/{action}": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/{id}/relations/{name}": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/{id}/relations/{name}/candidates": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/{id}/relations/{name}/link": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/{id}/relations/{name}/unlink": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}": classAllowsProtect, - "PUT /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/{id}/relations/{name}/delete": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/{id}/relations/{name}/pivot/{child}": classAllowsProtect, - "PUT /{vendor}/{plugin}/{controller}/{id}/relations/{name}/pivot/{child}": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}/files/{field}": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}/files/{field}": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}/files/{field}/reorder": classAllowsProtect, - "PUT /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}/files/{field}/{file}": classAllowsProtect, - "DELETE /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}/files/{field}/{file}": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/schema/list": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/schema/form": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/schema/relation/{name}": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/partials/{name}": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/fields/{field}/options": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/fields/{field}/dependent-options": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/filters/{scope}/options": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/bulk-delete": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/reorder": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/reorder": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/singleton": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/bulk/{action}": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/widgets/{field}": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/toolbar/{action}": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/{id}": classAllowsProtect, + "PUT /{vendor}/{plugin}/{controller}/{id}": classAllowsProtect, + "DELETE /{vendor}/{plugin}/{controller}/{id}": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/{id}/actions/{action}": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/{id}/relations/{name}": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/{id}/relations/{name}/candidates": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/{id}/relations/{name}/link": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/{id}/relations/{name}/unlink": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}": classAllowsProtect, + "PUT /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/{id}/relations/{name}/delete": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/{id}/relations/{name}/pivot/{child}": classAllowsProtect, + "PUT /{vendor}/{plugin}/{controller}/{id}/relations/{name}/pivot/{child}": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}/files/{field}": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}/files/{field}": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}/files/{field}/reorder": classAllowsProtect, + "PUT /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}/files/{field}/{file}": classAllowsProtect, + "DELETE /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}/files/{field}/{file}": classAllowsProtect, "GET /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}/files/{field}/{file}/download": classAllowsProtect, "GET /{vendor}/{plugin}/{controller}/{id}/relations/{name}/records/{child}/files/{field}/{file}/thumb": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/{id}/files/{field}": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/{id}/files/{field}": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/{id}/files/{field}/reorder": classAllowsProtect, - "PUT /{vendor}/{plugin}/{controller}/{id}/files/{field}/{file}": classAllowsProtect, - "DELETE /{vendor}/{plugin}/{controller}/{id}/files/{field}/{file}": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/{id}/files/{field}/{file}/download": classAllowsProtect, - "GET /{vendor}/{plugin}/{controller}/{id}/files/{field}/{file}/thumb": classAllowsProtect, - "POST /{vendor}/{plugin}/{controller}/{id}/fields/{field}/upload": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/{id}/files/{field}": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/{id}/files/{field}": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/{id}/files/{field}/reorder": classAllowsProtect, + "PUT /{vendor}/{plugin}/{controller}/{id}/files/{field}/{file}": classAllowsProtect, + "DELETE /{vendor}/{plugin}/{controller}/{id}/files/{field}/{file}": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/{id}/files/{field}/{file}/download": classAllowsProtect, + "GET /{vendor}/{plugin}/{controller}/{id}/files/{field}/{file}/thumb": classAllowsProtect, + "POST /{vendor}/{plugin}/{controller}/{id}/fields/{field}/upload": classAllowsProtect, "GET /assets/{vendor}/{plugin}/{file...}": classPublic, - "GET ": classPublic, - "GET /{path...}": classPublic, + "GET ": classPublic, + "GET /{path...}": classPublic, } func TestTokenRouteGates(t *testing.T) { diff --git a/modules/cabana/token_scopes_test.go b/modules/cabana/token_scopes_test.go index fda3f06a..ba1fee5c 100644 --- a/modules/cabana/token_scopes_test.go +++ b/modules/cabana/token_scopes_test.go @@ -91,9 +91,9 @@ func TestAllowsScope(t *testing.T) { p: dev, scope: &bouncer.ScopeLimit{Full: true}, required: nil, want: true, }, { - name: "plugin scope with owner grant", - p: dev, - scope: &bouncer.ScopeLimit{Scopes: [][]string{{"acme.demo.*"}}}, + name: "plugin scope with owner grant", + p: dev, + scope: &bouncer.ScopeLimit{Scopes: [][]string{{"acme.demo.*"}}}, required: []string{"acme.demo.access"}, want: true, }, { @@ -106,27 +106,27 @@ func TestAllowsScope(t *testing.T) { required: []string{"acme.demo.access"}, want: false, }, { - name: "superuser with scoped token limited", - p: super, - scope: &bouncer.ScopeLimit{Scopes: [][]string{{"acme.demo.reports"}}}, + name: "superuser with scoped token limited", + p: super, + scope: &bouncer.ScopeLimit{Scopes: [][]string{{"acme.demo.reports"}}}, required: []string{"acme.demo.access"}, want: false, }, { - name: "superuser scoped token matching scope code", - p: super, - scope: &bouncer.ScopeLimit{Scopes: [][]string{{"acme.demo.reports"}}}, + name: "superuser scoped token matching scope code", + p: super, + scope: &bouncer.ScopeLimit{Scopes: [][]string{{"acme.demo.reports"}}}, required: []string{"acme.demo.reports"}, want: true, }, { - name: "empty requirement list refused unless full", - p: dev, - scope: &bouncer.ScopeLimit{Scopes: [][]string{{"acme.demo.*"}}}, + name: "empty requirement list refused unless full", + p: dev, + scope: &bouncer.ScopeLimit{Scopes: [][]string{{"acme.demo.*"}}}, required: nil, want: false, }, { - name: "multi-code literal: one scope must match every code", - p: dev, - scope: &bouncer.ScopeLimit{Scopes: [][]string{{"acme.demo.*"}}}, + name: "multi-code literal: one scope must match every code", + p: dev, + scope: &bouncer.ScopeLimit{Scopes: [][]string{{"acme.demo.*"}}}, required: []string{"acme.demo.access", "acme.demo.reports"}, want: true, }, { @@ -148,9 +148,9 @@ func TestAllowsScope(t *testing.T) { required: []string{"acme.demo.*"}, want: true, }, { - name: "wildcard requirement equal pattern full", - p: dev, - scope: &bouncer.ScopeLimit{Scopes: [][]string{{"acme.demo.*"}}}, + name: "wildcard requirement equal pattern full", + p: dev, + scope: &bouncer.ScopeLimit{Scopes: [][]string{{"acme.demo.*"}}}, required: []string{"acme.demo.*"}, want: true, }, { diff --git a/modules/compass/config_test.go b/modules/compass/config_test.go index 6b6b3c2b..aacf1534 100644 --- a/modules/compass/config_test.go +++ b/modules/compass/config_test.go @@ -27,8 +27,8 @@ func TestLoadStringFromAppSection(t *testing.T) { func TestOpenDefaultsEnvToProduction(t *testing.T) { dir := writeConfigTree(t, map[string]string{ - "app.yaml": "name: base\ndebug: false\n", - "env/production/app.yaml": "debug: true\n", + "app.yaml": "name: base\ndebug: false\n", + "env/production/app.yaml": "debug: true\n", "env/development/app.yaml": "name: dev\n", }) cfg, err := Open(Options{Dir: dir, Environ: []string{}}) @@ -186,8 +186,8 @@ func TestEnvVarsOverridePluginDefaults(t *testing.T) { func TestPriorityRuntimeSetThenPersistThenEnvThenOverlayThenBaseThenPlugin(t *testing.T) { dir := writeConfigTree(t, map[string]string{ - "app.yaml": "name: base\n", - "env/development/app.yaml": "name: overlay\n", + "app.yaml": "name: base\n", + "env/development/app.yaml": "name: overlay\n", "env/development/overrides.yaml": "app:\n name: persisted\n", }) cfg, err := Open(Options{ @@ -408,7 +408,7 @@ func TestDotEnvDoesNotOverrideRealEnviron(t *testing.T) { func TestDottedPluginNamespaceAndTypedSection(t *testing.T) { dir := writeConfigTree(t, map[string]string{ - "app.yaml": "name: hello-app\n", + "app.yaml": "name: hello-app\n", "golem15.hello.yaml": "from_app: true\n", }) cfg, err := Open(Options{Dir: dir, Environ: []string{}}) diff --git a/modules/compass/persist_test.go b/modules/compass/persist_test.go index fc848f22..df0350e8 100644 --- a/modules/compass/persist_test.go +++ b/modules/compass/persist_test.go @@ -10,7 +10,7 @@ import ( func TestSetWinsOverPersistedOverrides(t *testing.T) { dir := writeConfigTree(t, map[string]string{ - "app.yaml": "name: base\n", + "app.yaml": "name: base\n", "env/development/overrides.yaml": "app:\n name: persisted\n", }) cfg, err := Open(Options{Dir: dir, Env: "development", Environ: []string{}}) diff --git a/modules/flare/commands.go b/modules/flare/commands.go index ddd8eb47..a288ae4f 100644 --- a/modules/flare/commands.go +++ b/modules/flare/commands.go @@ -234,7 +234,7 @@ or any send fails, after listing the common causes.`, {Command: TestPushCommandName + " 42", Description: "Send a test notification to user 42's browsers"}, {Command: TestPushCommandName + " 42 -n", Description: "Send without the confirmation question"}, }, - Args: []bonfire.Arg{{Name: "user_id", Description: "User ID to send test notification to", Required: true}}, + Args: []bonfire.Arg{{Name: "user_id", Description: "User ID to send test notification to", Required: true}}, Flags: []bonfire.Flag{ // Accepted for compatibility: the configuration is always shown. {Name: "show-config", Bare: true, Description: "Display current push configuration"}, diff --git a/modules/kiosk/manifest_smoke_test.go b/modules/kiosk/manifest_smoke_test.go index ec4de1ab..35f296af 100644 --- a/modules/kiosk/manifest_smoke_test.go +++ b/modules/kiosk/manifest_smoke_test.go @@ -483,7 +483,6 @@ func assertJSON(t *testing.T, v any, want string) { } } - // fakeTB records CheckT's calls. type fakeTB struct { helpers int diff --git a/modules/tide/flow_test.go b/modules/tide/flow_test.go index e85e2a3b..2b1e8666 100644 --- a/modules/tide/flow_test.go +++ b/modules/tide/flow_test.go @@ -55,10 +55,10 @@ func TestFlowMismatchContinuesAndCaptureSkipsRest(t *testing.T) { Name: "capture-skip", Steps: []Step{ { - ID: "a", - Request: Request{Method: http.MethodGet, Path: "/two"}, + ID: "a", + Request: Request{Method: http.MethodGet, Path: "/two"}, Response: Response{Status: 200, Headers: jsonCT(), Body: Body(`{"data":"ok"}`)}, - Capture: []CaptureRule{{From: "response.json", Path: "$.token", As: "jwt:alice"}}, + Capture: []CaptureRule{{From: "response.json", Path: "$.token", As: "jwt:alice"}}, }, { ID: "b", diff --git a/modules/tide/headers_test.go b/modules/tide/headers_test.go index 080d94d8..cabfcc2a 100644 --- a/modules/tide/headers_test.go +++ b/modules/tide/headers_test.go @@ -80,7 +80,7 @@ func TestHeadersReplayAgainstServer(t *testing.T) { Version: 1, Name: "headers", Steps: []Step{{ - ID: "h", + ID: "h", Request: Request{Method: http.MethodGet, Path: "/"}, Response: Response{ Status: 200,