Skip to content

Commit

Permalink
Generation of Job name for tests fixed
Browse files Browse the repository at this point in the history
Signed-off-by: Sergey Aksenov <[email protected]>
  • Loading branch information
k0taperk0t committed Oct 9, 2023
1 parent 4301258 commit 11c75e6
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions pkg/kube/job_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,9 @@ type JobSuite struct{}

var _ = Suite(&JobSuite{})

var testJobName = "kanister-test-job"
// Name of test job for this suite.
// Initially it contains incorrect name of job for catching errors.
var testJobName = "<unknown name>"

const testJobNamespace = "default"
const testJobImage = "busybox"
Expand All @@ -47,7 +49,7 @@ func (s *JobSuite) SetUpSuite(c *C) {
}

func (s *JobSuite) SetUpTest(c *C) {
testJobName = testJobName + rand.String(5)
testJobName = "kanister-test-job" + rand.String(5)
}

// Verifies that the Job object is not created if the job name is not specified.
Expand Down

0 comments on commit 11c75e6

Please sign in to comment.