Skip to content

Commit a02edba

Browse files
committed
retry test
1 parent 6a82d68 commit a02edba

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

iam/api-client/src/test/java/iam/snippets/ServiceAccountTests.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,15 @@
1919
import static org.hamcrest.core.StringContains.containsString;
2020
import static org.junit.Assert.assertNotNull;
2121

22+
import com.google.cloud.testing.junit4.MultipleAttemptsRule;
2223
import java.io.ByteArrayOutputStream;
2324
import java.io.PrintStream;
2425
import java.util.UUID;
2526
import org.junit.After;
2627
import org.junit.Before;
2728
import org.junit.BeforeClass;
2829
import org.junit.FixMethodOrder;
30+
import org.junit.Rule;
2931
import org.junit.Test;
3032
import org.junit.runner.RunWith;
3133
import org.junit.runners.JUnit4;
@@ -42,6 +44,8 @@ public class ServiceAccountTests {
4244
private ByteArrayOutputStream bout;
4345
private final PrintStream originalOut = System.out;
4446

47+
@Rule MultipleAttemptsRule multipleAttemptsRule = new MultipleAttemptsRule(3);
48+
4549
private static void requireEnvVar(String varName) {
4650
assertNotNull(
4751
System.getenv(varName),

0 commit comments

Comments
 (0)