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

Unified Diff: tools/telemetry/telemetry/page/actions/click_element_unittest.py

Issue 22989006: [telemetry] Change many relative paths to use util.Get*Dir(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase. Created 7 years, 4 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: tools/telemetry/telemetry/page/actions/click_element_unittest.py
diff --git a/tools/telemetry/telemetry/page/actions/click_element_unittest.py b/tools/telemetry/telemetry/page/actions/click_element_unittest.py
index 03eb87aa383454443ee5f72f0655a79817e0dc0b..a32baec352918dea3b7379c04a01ddaae87766e6 100644
--- a/tools/telemetry/telemetry/page/actions/click_element_unittest.py
+++ b/tools/telemetry/telemetry/page/actions/click_element_unittest.py
@@ -1,16 +1,14 @@
# Copyright (c) 2012 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
-import os
+from telemetry.core import util
from telemetry.page.actions import click_element
from telemetry.unittest import tab_test_case
class ClickElementActionTest(tab_test_case.TabTestCase):
def testClickWithSelectorWaitForNavigation(self):
- unittest_data_dir = os.path.join(os.path.dirname(__file__),
- '..', '..', '..', 'unittest_data')
- self._browser.SetHTTPServerDirectories(unittest_data_dir)
+ self._browser.SetHTTPServerDirectories(util.GetUnittestDataDir())
self._tab.Navigate(
self._browser.http_server.UrlOf('page_with_link.html'))
self._tab.WaitForDocumentReadyStateToBeComplete()
@@ -27,9 +25,7 @@ class ClickElementActionTest(tab_test_case.TabTestCase):
'/blank.html')
def testClickWithTextWaitForRefChange(self):
- unittest_data_dir = os.path.join(os.path.dirname(__file__),
- '..', '..', '..', 'unittest_data')
- self._browser.SetHTTPServerDirectories(unittest_data_dir)
+ self._browser.SetHTTPServerDirectories(util.GetUnittestDataDir())
self._tab.Navigate(
self._browser.http_server.UrlOf('page_with_link.html'))
self._tab.WaitForDocumentReadyStateToBeComplete()

Powered by Google App Engine
This is Rietveld 408576698