Skip to content

Commit 3242fae

Browse files
committed
chore(spanner): skip tests if mur for rw is enabled
1 parent ff6f80e commit 3242fae

File tree

2 files changed

+185
-3
lines changed

2 files changed

+185
-3
lines changed

google-cloud-spanner/src/test/java/com/google/cloud/spanner/MockSpannerServiceImpl.java

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1896,7 +1896,8 @@ public void beginTransaction(
18961896
beginTransactionExecutionTime.simulateExecutionTime(
18971897
exceptions, stickyGlobalExceptions, freezeLock);
18981898
Transaction transaction =
1899-
beginTransaction(session, request.getOptions(), request.getMutationKey(), request.getRequestOptions());
1899+
beginTransaction(
1900+
session, request.getOptions(), request.getMutationKey(), request.getRequestOptions());
19001901
responseObserver.onNext(transaction);
19011902
responseObserver.onCompleted();
19021903
} catch (StatusRuntimeException t) {
@@ -1907,7 +1908,10 @@ public void beginTransaction(
19071908
}
19081909

19091910
private Transaction beginTransaction(
1910-
Session session, TransactionOptions options, com.google.spanner.v1.Mutation mutationKey, RequestOptions requestOptions) {
1911+
Session session,
1912+
TransactionOptions options,
1913+
com.google.spanner.v1.Mutation mutationKey,
1914+
RequestOptions requestOptions) {
19111915
ByteString transactionId = generateTransactionName(session.getName());
19121916
Transaction.Builder builder = Transaction.newBuilder().setId(transactionId);
19131917
if (options != null && options.getModeCase() == ModeCase.READ_ONLY) {
@@ -1922,7 +1926,8 @@ private Transaction beginTransaction(
19221926
Transaction transaction = builder.build();
19231927
transactions.put(transaction.getId(), transaction);
19241928
// Do not add transaction id to transactionsStarted if this request was from background thread
1925-
if (requestOptions == null || !requestOptions.getTransactionTag().equals("multiplexed-rw-background-begin-txn")) {
1929+
if (requestOptions == null
1930+
|| !requestOptions.getTransactionTag().equals("multiplexed-rw-background-begin-txn")) {
19261931
transactionsStarted.add(transaction.getId());
19271932
}
19281933
isPartitionedDmlTransaction.put(

0 commit comments

Comments
 (0)