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

Unified Diff: chrome/browser/importer/importer_unittest_utils.h

Issue 13954013: Port some importer unit tests to browser tests to be able to fully exercise the ExternalProcessImpo… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix includes post-merge Created 7 years, 8 months 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: chrome/browser/importer/importer_unittest_utils.h
diff --git a/chrome/browser/importer/importer_unittest_utils.h b/chrome/browser/importer/importer_unittest_utils.h
index 3b054a8eb262365d33626fbf8ac95e695ef93466..ee225b19b8a5ff66c0581499dadd0dedb74aef07 100644
--- a/chrome/browser/importer/importer_unittest_utils.h
+++ b/chrome/browser/importer/importer_unittest_utils.h
@@ -5,17 +5,7 @@
#ifndef CHROME_BROWSER_IMPORTER_IMPORTER_UNITTEST_UTILS_H_
#define CHROME_BROWSER_IMPORTER_IMPORTER_UNITTEST_UTILS_H_
-#include "base/files/scoped_temp_dir.h"
-#include "base/message_loop.h"
#include "chrome/browser/importer/profile_writer.h"
-#include "content/public/test/test_browser_thread.h"
-#include "testing/gtest/include/gtest/gtest.h"
-
-namespace importer {
-class ImporterProgressObserver;
-}
-
-class TestingProfile;
const int kMaxPathSize = 5;
@@ -27,32 +17,10 @@ struct BookmarkInfo {
const char* url;
};
-// Returns true if the |entry| is equal to |expected|.
-bool EqualBookmarkEntry(const ProfileWriter::BookmarkEntry& entry,
- const BookmarkInfo& expected);
-
-// Returns true if the |entry| is in the |list|.
-bool FindBookmarkEntry(const ProfileWriter::BookmarkEntry& entry,
- const BookmarkInfo* list,
- int list_size);
-
-// Test fixture class providing a message loop, ui/file thread,
-// and a scoped temporary directory.
-class ImporterTest : public testing::Test {
- public:
- ImporterTest();
- virtual ~ImporterTest();
-
- protected:
- virtual void SetUp() OVERRIDE;
-
- base::ScopedTempDir temp_dir_;
- scoped_ptr<TestingProfile> profile_;
-
- private:
- MessageLoopForUI message_loop_;
- content::TestBrowserThread ui_thread_;
- content::TestBrowserThread file_thread_;
-};
+// Generates an assertion error if |entry| is not equal to |expected|. Wrap this
+// method in (ASSERT|EXPECT)_NO_FATAL_FAILURE to catch the error if one is
+// generated.
+void TestEqualBookmarkEntry(const ProfileWriter::BookmarkEntry& entry,
+ const BookmarkInfo& expected);
#endif // CHROME_BROWSER_IMPORTER_IMPORTER_UNITTEST_UTILS_H_
« no previous file with comments | « chrome/browser/importer/ie_importer_unittest_win.cc ('k') | chrome/browser/importer/importer_unittest_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698