Index: chrome/browser/importer/importer_unittest_utils.cc |
diff --git a/chrome/browser/importer/importer_unittest_utils.cc b/chrome/browser/importer/importer_unittest_utils.cc |
index ff6d79646c0a0e55bba8047bc88213776fee96f5..dd0e6c0c3252e40af49c16e685948b9bf3bd6232 100644 |
--- a/chrome/browser/importer/importer_unittest_utils.cc |
+++ b/chrome/browser/importer/importer_unittest_utils.cc |
@@ -5,41 +5,14 @@ |
#include "chrome/browser/importer/importer_unittest_utils.h" |
#include "base/utf_string_conversions.h" |
-#include "chrome/test/base/testing_profile.h" |
+#include "testing/gtest/include/gtest/gtest.h" |
-bool EqualBookmarkEntry(const ProfileWriter::BookmarkEntry& entry, |
- const BookmarkInfo& expected) { |
- if (expected.in_toolbar != entry.in_toolbar || |
- expected.path_size != entry.path.size() || |
- expected.url != entry.url.spec() || |
- WideToUTF16Hack(expected.title) != entry.title) |
- return false; |
- for (size_t i = 0; i < expected.path_size; ++i) { |
- if (WideToUTF16Hack(expected.path[i]) != entry.path[i]) |
- return false; |
- } |
- return true; |
-} |
- |
-bool FindBookmarkEntry(const ProfileWriter::BookmarkEntry& entry, |
- const BookmarkInfo* list, int list_size) { |
- for (int i = 0; i < list_size; ++i) { |
- if (EqualBookmarkEntry(entry, list[i])) |
- return true; |
- } |
- return false; |
-} |
- |
-ImporterTest::ImporterTest() |
- : profile_(new TestingProfile()), |
- ui_thread_(content::BrowserThread::UI, &message_loop_), |
- file_thread_(content::BrowserThread::FILE, &message_loop_) { |
-} |
- |
-ImporterTest::~ImporterTest() { |
- profile_.reset(NULL); |
-} |
- |
-void ImporterTest::SetUp() { |
- ASSERT_TRUE(temp_dir_.CreateUniqueTempDir()); |
+void TestEqualBookmarkEntry(const ProfileWriter::BookmarkEntry& entry, |
+ const BookmarkInfo& expected) { |
+ ASSERT_EQ(WideToUTF16Hack(expected.title), entry.title); |
+ ASSERT_EQ(expected.in_toolbar, entry.in_toolbar) << entry.title; |
+ ASSERT_EQ(expected.path_size, entry.path.size()) << entry.title; |
+ ASSERT_EQ(expected.url, entry.url.spec()) << entry.title; |
+ for (size_t i = 0; i < expected.path_size; ++i) |
+ ASSERT_EQ(WideToUTF16Hack(expected.path[i]), entry.path[i]) << entry.title; |
} |