| Index: telemetry/telemetry/internal/actions/drag_unittest.py
|
| diff --git a/telemetry/telemetry/internal/actions/drag_unittest.py b/telemetry/telemetry/internal/actions/drag_unittest.py
|
| index 439ade62c920de5fd780212aa24542eaa0078d45..82bffc8ddd2ba4b389f4e740ac3ac0402ca0375d 100644
|
| --- a/telemetry/telemetry/internal/actions/drag_unittest.py
|
| +++ b/telemetry/telemetry/internal/actions/drag_unittest.py
|
| @@ -1,13 +1,14 @@
|
| # Copyright 2015 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 logging
|
| import math
|
| -import os
|
|
|
| from telemetry import decorators
|
| from telemetry.internal.actions import drag
|
| from telemetry.internal.actions import page_action
|
| +from telemetry.internal.actions import utils
|
| from telemetry.testing import tab_test_case
|
|
|
|
|
| @@ -20,10 +21,7 @@ class DragActionTest(tab_test_case.TabTestCase):
|
| def testDragAction(self):
|
| self.Navigate('draggable.html')
|
|
|
| - with open(os.path.join(os.path.dirname(__file__),
|
| - 'gesture_common.js')) as f:
|
| - js = f.read()
|
| - self._tab.ExecuteJavaScript(js)
|
| + utils.InjectJavaScript(self._tab, 'gesture_common.js')
|
|
|
| div_width = self._tab.EvaluateJavaScript(
|
| '__GestureCommon_GetBoundingVisibleRect(document.body).width')
|
|
|