| Index: tools/telemetry/telemetry/page/actions/action_runner.py
|
| diff --git a/tools/telemetry/telemetry/page/actions/action_runner.py b/tools/telemetry/telemetry/page/actions/action_runner.py
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..36a7e10a5f7d99e7aa871c75a2f8ade7c8b65d18
|
| --- /dev/null
|
| +++ b/tools/telemetry/telemetry/page/actions/action_runner.py
|
| @@ -0,0 +1,19 @@
|
| +# Copyright (c) 2014 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.
|
| +
|
| +class ActionRunner(object):
|
| + def __init__(self, page, tab, page_test=None):
|
| + self._page = page
|
| + self._tab = tab
|
| + self._page_test = page_test
|
| +
|
| + def RunAction(self, action):
|
| + action.WillRunAction(self._page, self._tab)
|
| + if self._page_test:
|
| + self._page_test.WillRunAction(self._page, self._tab, action)
|
| +
|
| + action.RunAction(self._page, self._tab, None)
|
| +
|
| + if self._page_test:
|
| + self._page_test.DidRunAction(self._page, self._tab, action)
|
|
|