Skip to content

Commit

Permalink
Enable bool-literal-in-expr revive flag
Browse files Browse the repository at this point in the history
Signed-off-by: Elena Gershkovich <elenage@il.ibm.com>
  • Loading branch information
ELENAGER committed Dec 13, 2023
1 parent 6559c0b commit bc6dd0c
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .golangci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ linters-settings:
# - name: confusing-naming
# - name: import-shadowing
- name: confusing-results
# - name: bool-literal-in-expr
- name: bool-literal-in-expr

issues:
exclude-rules:
Expand Down
2 changes: 1 addition & 1 deletion controllers/drcluster_mmode_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ var _ = Describe("DRClusterMModeTests", Ordered, func() {
},
}

if testEnv.UseExistingCluster != nil && *testEnv.UseExistingCluster == true {
if testEnv.UseExistingCluster != nil && *testEnv.UseExistingCluster {
namespaceDeletionSupported = true
}

Expand Down
2 changes: 1 addition & 1 deletion controllers/drpc_predicate_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ var _ = Describe("DRPCPredicateDRCluster", func() {
},
}

if testEnv.UseExistingCluster != nil && *testEnv.UseExistingCluster == true {
if testEnv.UseExistingCluster != nil && *testEnv.UseExistingCluster {
namespaceDeletionSupported = true
}

Expand Down
2 changes: 1 addition & 1 deletion controllers/suite_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ var _ = BeforeSuite(func() {
},
}

if testEnv.UseExistingCluster != nil && *testEnv.UseExistingCluster == true {
if testEnv.UseExistingCluster != nil && *testEnv.UseExistingCluster {
namespaceDeletionSupported = true
}

Expand Down
4 changes: 2 additions & 2 deletions controllers/vrg_volrep_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1481,7 +1481,7 @@ func (v *vrgTest) verifyPVCBindingToPV(shouldBeBound bool) {
Eventually(func() bool {
pvc := getPVC(v.pvcNames[i])

if shouldBeBound == true {
if shouldBeBound {
return pvc.Status.Phase == corev1.ClaimBound
}

Expand Down Expand Up @@ -1543,7 +1543,7 @@ func (v *vrgTest) verifyVRGStatusExpectation(expectedStatus bool) {
return false
}

if expectedStatus == true {
if expectedStatus {
// reasons for success can be different for Primary and
// secondary. Validate that as well.
switch vrg.Spec.ReplicationState {
Expand Down

0 comments on commit bc6dd0c

Please sign in to comment.