Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(8)

Unified Diff: components/sync/engine_impl/syncer_unittest.cc

Issue 2455343003: [Sync] Replaced ASSERT/EXPECT_TRUE/FALSE with expected/actual checks. (Closed)
Patch Set: \Updates for Max and rebase. Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: components/sync/engine_impl/syncer_unittest.cc
diff --git a/components/sync/engine_impl/syncer_unittest.cc b/components/sync/engine_impl/syncer_unittest.cc
index 3de14a11f909e745c725aee5c97a57c8731bfb7b..1cc74b66c134d178859bfa490f9fed8b97f6132e 100644
--- a/components/sync/engine_impl/syncer_unittest.cc
+++ b/components/sync/engine_impl/syncer_unittest.cc
@@ -455,8 +455,7 @@ class SyncerTest : public testing::Test,
}
}
EXPECT_TRUE(SyncShareNudge());
- ASSERT_TRUE(expected_positions.size() ==
- mock_server_->committed_ids().size());
+ ASSERT_EQ(expected_positions.size(), mock_server_->committed_ids().size());
// If this test starts failing, be aware other sort orders could be valid.
for (size_t i = 0; i < expected_positions.size(); ++i) {
SCOPED_TRACE(i);
@@ -1951,7 +1950,7 @@ TEST_F(SyncerTest, TestCommitListOrderingAndNewParentAndChild) {
Entry entry_b(&rtrans, GET_BY_HANDLE, meta_handle_b);
EXPECT_TRUE(entry_b.GetId().ServerKnows());
- EXPECT_TRUE(parent2.GetId() == entry_b.GetParentId());
+ EXPECT_EQ(parent2.GetId(), entry_b.GetParentId());
}
}
@@ -2105,13 +2104,13 @@ TEST_F(SyncerTest, IllegalAndLegalUpdates) {
EXPECT_EQ(root, rename.GetParentId());
EXPECT_EQ("new_name", rename.GetNonUniqueName());
EXPECT_FALSE(rename.GetIsUnappliedUpdate());
- EXPECT_TRUE(ids_.FromNumber(1) == rename.GetId());
+ EXPECT_EQ(ids_.FromNumber(1), rename.GetId());
EXPECT_EQ(20u, rename.GetBaseVersion());
Entry name_clash(&trans, GET_BY_ID, ids_.FromNumber(2));
ASSERT_TRUE(name_clash.good());
EXPECT_EQ(root, name_clash.GetParentId());
- EXPECT_TRUE(ids_.FromNumber(2) == name_clash.GetId());
+ EXPECT_EQ(ids_.FromNumber(2), name_clash.GetId());
EXPECT_EQ(10u, name_clash.GetBaseVersion());
EXPECT_EQ("in_root", name_clash.GetNonUniqueName());
« no previous file with comments | « components/sync/driver/sync_stopped_reporter_unittest.cc ('k') | components/sync/syncable/directory_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698