Skip to content
This repository was archived by the owner on Sep 27, 2019. It is now read-only.

Commit 8f48f47

Browse files
authored
Merge branch 'master' into tianyu-protocol-refactor-structure
2 parents 7b84245 + cd681eb commit 8f48f47

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

test/concurrency/serializable_transaction_test.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,8 @@ TEST_F(SerializableTransactionTests, ReadOnlyTransactionTest) {
7676

7777
//manually update snapshot epoch number, so later snapshot read must get a larger epoch than table creating txn
7878
//or it may read nothing
79-
//wait one epoch. so that global epoch is guaranteed to increase
80-
std::this_thread::sleep_for(std::chrono::milliseconds(EPOCH_LENGTH));
79+
//wait two epochs. so that global epoch is guaranteed to increase
80+
std::this_thread::sleep_for(std::chrono::milliseconds(2 * EPOCH_LENGTH));
8181
concurrency::EpochManagerFactory::GetInstance().GetExpiredEpochId();
8282

8383
TransactionScheduler scheduler(1, table, &txn_manager, {0});
@@ -86,6 +86,8 @@ TEST_F(SerializableTransactionTests, ReadOnlyTransactionTest) {
8686

8787
scheduler.Run();
8888

89+
EXPECT_EQ(ResultType::SUCCESS, scheduler.schedules[0].txn_result);
90+
8991
//it should read all the 10 tuples
9092
EXPECT_EQ(10, scheduler.schedules[0].results.size());
9193

0 commit comments

Comments
 (0)