diff options
author | maniscalco@chromium.org <maniscalco@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-03-01 01:24:24 +0000 |
---|---|---|
committer | maniscalco@chromium.org <maniscalco@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-03-01 01:24:24 +0000 |
commit | 3ad2398165694ba9243b7f9539d367ba3122f9ef (patch) | |
tree | c4c73c68fc94d498e81a236246b8a26fdacfa750 /sync | |
parent | d8c1b1229b4bbc95c21ab12c766977017c2bff70 (diff) | |
download | chromium_src-3ad2398165694ba9243b7f9539d367ba3122f9ef.zip chromium_src-3ad2398165694ba9243b7f9539d367ba3122f9ef.tar.gz chromium_src-3ad2398165694ba9243b7f9539d367ba3122f9ef.tar.bz2 |
Don't call RefreshColumns() in directory_backing_store_unittest.cc.
Move "column deleted" checks from test case MigrateVersion85To86 to test
case ToCurrentVersion where they will execute after a RefreshColumns().
RefreshColumns() should not be called from MigrateVersionXToY test cases
because it will create in a metas table with all columns know to the
code (i.e. the latest version).
BUG=
Review URL: https://codereview.chromium.org/182683004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@254310 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'sync')
-rw-r--r-- | sync/syncable/directory_backing_store_unittest.cc | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sync/syncable/directory_backing_store_unittest.cc b/sync/syncable/directory_backing_store_unittest.cc index c40d564..f53dfb7 100644 --- a/sync/syncable/directory_backing_store_unittest.cc +++ b/sync/syncable/directory_backing_store_unittest.cc @@ -2980,10 +2980,6 @@ TEST_F(DirectoryBackingStoreTest, MigrateVersion85To86) { EXPECT_TRUE(connection.DoesColumnExist("metas", "server_unique_position")); EXPECT_TRUE(connection.DoesColumnExist("metas", "unique_bookmark_tag")); ASSERT_TRUE(dbs->needs_column_refresh_); - ASSERT_TRUE(dbs->RefreshColumns()); - EXPECT_FALSE(connection.DoesColumnExist("metas", "next_id")); - EXPECT_FALSE(connection.DoesColumnExist("metas", "prev_id")); - EXPECT_FALSE(connection.DoesColumnExist("metas", "server_ordinal_in_parent")); { Directory::MetahandlesMap handles_map; @@ -3236,6 +3232,11 @@ TEST_P(MigrationTest, ToCurrentVersion) { // Column removed in version 85. ASSERT_FALSE(connection.DoesColumnExist("models", "initial_sync_ended")); + // Columns removed in version 86. + ASSERT_FALSE(connection.DoesColumnExist("metas", "next_id")); + ASSERT_FALSE(connection.DoesColumnExist("metas", "prev_id")); + ASSERT_FALSE(connection.DoesColumnExist("metas", "server_ordinal_in_parent")); + // Check download_progress state (v75 migration) ASSERT_EQ(694, dir_info.kernel_info.download_progress[BOOKMARKS] |