Skip to content

Commit

Permalink
test: skip test on emulator
Browse files Browse the repository at this point in the history
  • Loading branch information
olavloite committed Jul 30, 2020
1 parent f30334e commit a4d2e76
Showing 1 changed file with 4 additions and 3 deletions.
Expand Up @@ -28,7 +28,6 @@
import com.google.cloud.spanner.BatchReadOnlyTransaction;
import com.google.cloud.spanner.Database;
import com.google.cloud.spanner.DatabaseClient;
import com.google.cloud.spanner.DatabaseId;
import com.google.cloud.spanner.ErrorCode;
import com.google.cloud.spanner.IntegrationTestEnv;
import com.google.cloud.spanner.Key;
Expand Down Expand Up @@ -555,6 +554,10 @@ public Void run(TransactionContext transaction) throws SpannerException {

@Test
public void testTxWithCaughtError() {
assumeFalse(
"Emulator does not recover from an error within a transaction",
env.getTestHelper().isEmulator());

long updateCount =
client
.readWriteTransaction()
Expand Down Expand Up @@ -595,8 +598,6 @@ public Long run(TransactionContext transaction) throws Exception {

@Test
public void testTxWithUncaughtErrorAfterSuccessfulBegin() {
DatabaseClient client =
spanner.getDatabaseClient(DatabaseId.of("[PROJECT]", "[INSTANCE]", "[DATABASE]"));
try {
client
.readWriteTransaction()
Expand Down

0 comments on commit a4d2e76

Please sign in to comment.