2
0

Use ++ instead of += 1

This commit is contained in:
Jack Christensen
2020-05-07 20:25:38 -05:00
parent f9ce8af5c9
commit f18351f61c
3 changed files with 4 additions and 4 deletions
+2 -2
View File
@@ -108,7 +108,7 @@ func TestPoolBeforeAcquire(t *testing.T) {
acquireAttempts := 0
config.BeforeAcquire = func(ctx context.Context, c *pgx.Conn) bool {
acquireAttempts += 1
acquireAttempts++
return acquireAttempts%2 == 0
}
@@ -149,7 +149,7 @@ func TestPoolAfterRelease(t *testing.T) {
afterReleaseCount := 0
config.AfterRelease = func(c *pgx.Conn) bool {
afterReleaseCount += 1
afterReleaseCount++
return afterReleaseCount%2 == 1
}