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

Unified Diff: build/android/pylib/uirobot/uirobot_test_instance.py

Issue 745793002: Add AMP support to test runner. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: get rid of old/done TODOs Created 6 years, 1 month 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: build/android/pylib/uirobot/uirobot_test_instance.py
diff --git a/build/android/pylib/uirobot/uirobot_test_instance.py b/build/android/pylib/uirobot/uirobot_test_instance.py
new file mode 100644
index 0000000000000000000000000000000000000000..036933aacfb303746781cdd9322b4c2cb24e1998
--- /dev/null
+++ b/build/android/pylib/uirobot/uirobot_test_instance.py
@@ -0,0 +1,56 @@
+# Copyright 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.
+
+import os
+
+from pylib import constants
+from pylib.base import test_instance
+
+class UirobotTestInstance(test_instance.TestInstance):
jbudorick 2014/11/30 22:57:02 Will we run uirobot tests in any other environment
rnephew (Reviews Here) 2014/12/02 19:47:49 In theory we could, if appurify gives us the test.
+
+ def __init__(self, options):
+ """Constructor.
+
+ Args:
+ options: Command line options.
+ """
+ super(UirobotTestInstance, self).__init__()
+ self._apk_under_test = os.path.join(
+ constants.GetOutDirectory(), 'apks', 'Chrome.apk')
jbudorick 2014/11/30 22:57:02 This shouldn't be hard-coded.
rnephew (Reviews Here) 2014/12/02 19:47:49 Done.
+ self._minutes=options.minutes
jbudorick 2014/11/30 22:57:02 nit: spaces around =
rnephew (Reviews Here) 2014/12/02 19:47:49 Done.
+
+ #override
+ def TestType(self):
+ """Returns type of test."""
+ return 'uirobot'
+
+ #override
+ def SetUp(self):
+ """Setup for test."""
+ pass
+
+ #override
+ def TearDown(self):
+ """Teardown for test."""
+ pass
+
+ @property
+ def apk(self):
+ """Returns the name of the test to look for."""
+ return 'uirobot'
+
+ @property
+ def apk_under_test(self):
+ """Returns the app to run the test on."""
+ return self._apk_under_test
+
+ @property
+ def suite(self):
+ """Returns the test suite, none for uirobot."""
+ return None
+
+ @property
+ def minutes(self):
+ """Returns the number of minutes to run the uirobot for."""
+ return self._minutes

Powered by Google App Engine
This is Rietveld 408576698