summaryrefslogtreecommitdiffstats
path: root/chrome/test/ui_test_utils.cc
diff options
context:
space:
mode:
authorkkania@chromium.org <kkania@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-01-20 21:50:03 +0000
committerkkania@chromium.org <kkania@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-01-20 21:50:03 +0000
commitc70013bd3f8f695abe9b5d96e992c669557d6f60 (patch)
tree35106ded2a4d6cdfac8b6fddc410e6932dd65807 /chrome/test/ui_test_utils.cc
parentcb2131e3818ad8fb2f78db93140be7e0be48e64b (diff)
downloadchromium_src-c70013bd3f8f695abe9b5d96e992c669557d6f60.zip
chromium_src-c70013bd3f8f695abe9b5d96e992c669557d6f60.tar.gz
chromium_src-c70013bd3f8f695abe9b5d96e992c669557d6f60.tar.bz2
Add 3 tests for extension installation. Fix and re-enable UpdatePermissions test.
BUG=none TEST=none Review URL: http://codereview.chromium.org/547017 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@36679 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/test/ui_test_utils.cc')
-rw-r--r--chrome/test/ui_test_utils.cc9
1 files changed, 9 insertions, 0 deletions
diff --git a/chrome/test/ui_test_utils.cc b/chrome/test/ui_test_utils.cc
index add23d5..db83689 100644
--- a/chrome/test/ui_test_utils.cc
+++ b/chrome/test/ui_test_utils.cc
@@ -12,8 +12,10 @@
#include "base/process_util.h"
#include "base/values.h"
#include "chrome/browser/browser.h"
+#include "chrome/browser/browser_list.h"
#include "chrome/browser/dom_operation_notification_details.h"
#include "chrome/browser/download/download_manager.h"
+#include "chrome/browser/profile.h"
#include "chrome/browser/renderer_host/render_process_host.h"
#include "chrome/browser/tab_contents/navigation_controller.h"
#include "chrome/browser/tab_contents/navigation_entry.h"
@@ -370,6 +372,13 @@ void WaitForLoadStop(NavigationController* controller) {
new_tab_observer(NotificationType::LOAD_STOP, controller);
}
+void OpenURLOffTheRecord(Profile* profile, const GURL& url) {
+ Browser::OpenURLOffTheRecord(profile, url);
+ Browser* browser = BrowserList::FindBrowserWithType(
+ profile->GetOffTheRecordProfile(), Browser::TYPE_NORMAL);
+ WaitForNavigations(&browser->GetSelectedTabContents()->controller(), 1);
+}
+
void NavigateToURL(Browser* browser, const GURL& url) {
NavigateToURLBlockUntilNavigationsComplete(browser, url, 1);
}