mirror of
https://github.com/golang/go
synced 2024-11-18 15:44:41 -07:00
all: simplify bool conditions
Change-Id: Id2079f7012392dea8dfe2386bb9fb1ea3f487a4a Reviewed-on: https://go-review.googlesource.com/c/go/+/526015 Reviewed-by: Matthew Dempsky <mdempsky@google.com> Auto-Submit: Ian Lance Taylor <iant@google.com> Reviewed-by: Ian Lance Taylor <iant@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: qiulaidongfeng <2645477756@qq.com>
This commit is contained in:
parent
bebf82cbf6
commit
da8f406f06
@ -16,7 +16,7 @@ import (
|
||||
// implementation cannot be used.
|
||||
// See also TestBlockGeneric.
|
||||
func TestGenericPath(t *testing.T) {
|
||||
if useAsm == false {
|
||||
if !useAsm {
|
||||
t.Skipf("assembly implementation unavailable")
|
||||
}
|
||||
useAsm = false
|
||||
|
@ -16,7 +16,7 @@ import (
|
||||
// implementation cannot be used.
|
||||
// See also TestBlockGeneric.
|
||||
func TestGenericPath(t *testing.T) {
|
||||
if useAsm == false {
|
||||
if !useAsm {
|
||||
t.Skipf("assembly implementation unavailable")
|
||||
}
|
||||
useAsm = false
|
||||
|
@ -3769,7 +3769,7 @@ func TestIssue18719(t *testing.T) {
|
||||
cancel()
|
||||
|
||||
// Wait for the context to cancel and tx to rollback.
|
||||
for tx.isDone() == false {
|
||||
for !tx.isDone() {
|
||||
time.Sleep(pollDuration)
|
||||
}
|
||||
}
|
||||
|
@ -15,7 +15,7 @@ import (
|
||||
// vector-capable machine
|
||||
|
||||
func TestFunVVnovec(t *testing.T) {
|
||||
if hasVX == true {
|
||||
if hasVX {
|
||||
for _, a := range sumVV {
|
||||
arg := a
|
||||
testFunVV(t, "addVV_novec", addVV_novec, arg)
|
||||
|
@ -849,7 +849,7 @@ func TestReadResponseErrors(t *testing.T) {
|
||||
type testCase struct {
|
||||
name string // optional, defaults to in
|
||||
in string
|
||||
wantErr any // nil, err value, or string substring
|
||||
wantErr any // nil, err value, bool value, or string substring
|
||||
}
|
||||
|
||||
status := func(s string, wantErr any) testCase {
|
||||
|
Loading…
Reference in New Issue
Block a user