Skip to content

Commit 7a516c8

Browse files
committed
clean up unnecessary require.NoError; use require.NoError instead of t.Fatal for consistency
1 parent 734ef15 commit 7a516c8

File tree

2 files changed

+3
-10
lines changed

2 files changed

+3
-10
lines changed

integration/bundle/deploy_to_shared_test.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,6 @@ func TestDeployBasicToSharedWorkspacePath(t *testing.T) {
2525
"spark_version": defaultSparkVersion,
2626
"root_path": fmt.Sprintf("/Shared/%s", currentUser.UserName),
2727
})
28-
require.NoError(t, err)
2928

3029
t.Cleanup(func() {
3130
destroyBundle(wt, ctx, bundleRoot)

integration/bundle/helpers_test.go

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -84,19 +84,15 @@ func deployBundle(t testutil.TestingT, ctx context.Context, path string) {
8484
ctx = env.Set(ctx, "BUNDLE_ROOT", path)
8585
c := testcli.NewRunnerWithContext(t, ctx, "bundle", "deploy", "--force-lock", "--auto-approve")
8686
_, _, err := c.Run()
87-
if err != nil {
88-
t.Fatal(err)
89-
}
87+
require.NoError(t, err)
9088
}
9189

9290
func deployBundleWithArgs(t testutil.TestingT, ctx context.Context, path string, args ...string) (string, string) {
9391
ctx = env.Set(ctx, "BUNDLE_ROOT", path)
9492
args = append([]string{"bundle", "deploy"}, args...)
9593
c := testcli.NewRunnerWithContext(t, ctx, args...)
9694
stdout, stderr, err := c.Run()
97-
if err != nil {
98-
t.Fatal(err)
99-
}
95+
require.NoError(t, err)
10096
return stdout.String(), stderr.String()
10197
}
10298

@@ -106,9 +102,7 @@ func deployBundleWithFlags(t testutil.TestingT, ctx context.Context, path string
106102
args = append(args, flags...)
107103
c := testcli.NewRunnerWithContext(t, ctx, args...)
108104
_, _, err := c.Run()
109-
if err != nil {
110-
t.Fatal(err)
111-
}
105+
require.NoError(t, err)
112106
}
113107

114108
func runResource(t testutil.TestingT, ctx context.Context, path, key string) (string, error) {

0 commit comments

Comments
 (0)