summaryrefslogtreecommitdiffstats
path: root/chrome/test
diff options
context:
space:
mode:
authorsbasi@google.com <sbasi@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2013-01-25 00:30:44 +0000
committersbasi@google.com <sbasi@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2013-01-25 00:30:44 +0000
commit9c6cf766d3a58701bfb6cf957c2936d0ca81b1c4 (patch)
treeac3ff53dcef5b6870b71d27e5cd5d94d4bd17053 /chrome/test
parent989738aa9b54e3b08e098a821b49cfa0c567c551 (diff)
downloadchromium_src-9c6cf766d3a58701bfb6cf957c2936d0ca81b1c4.zip
chromium_src-9c6cf766d3a58701bfb6cf957c2936d0ca81b1c4.tar.gz
chromium_src-9c6cf766d3a58701bfb6cf957c2936d0ca81b1c4.tar.bz2
Autotest: Add telemetry dep to the chrome repo.
In order to add telemetry to the Autotest Lab for ChromeOS we need to package the telemetry source for this Chrome Build. The first steps in doing so is to add the telemetry_dep folder to the Chrome Source so that we can modify the ChromeOS ebuild files to package it properly into the autotest tarball. BUG=chromium-os:37409 TEST=Built chromeos-chrome using this local source to ensure that the dep-telemetry tarbar was created properly. Review URL: https://chromiumcodereview.appspot.com/12042085 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@178712 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/test')
-rw-r--r--chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/README6
-rw-r--r--chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/common.py12
-rw-r--r--chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/control5
-rwxr-xr-xchrome/test/chromeos/autotest/files/client/deps/telemetry_dep/setup_test_links.sh18
-rwxr-xr-xchrome/test/chromeos/autotest/files/client/deps/telemetry_dep/telemetry_dep.py22
5 files changed, 63 insertions, 0 deletions
diff --git a/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/README b/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/README
new file mode 100644
index 0000000..c3c2352
--- /dev/null
+++ b/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/README
@@ -0,0 +1,6 @@
+# Copyright (c) 2013 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.
+
+This dep brings Telemetry files into an image. Tests that depend on
+telemetry_dep should add this as a dep in their setup() method.
diff --git a/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/common.py b/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/common.py
new file mode 100644
index 0000000..ec9b614
--- /dev/null
+++ b/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/common.py
@@ -0,0 +1,12 @@
+# Copyright (c) 2013 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, sys
+dirname = os.path.dirname(sys.modules[__name__].__file__)
+client_dir = os.path.abspath(os.path.join(dirname, "../../"))
+sys.path.insert(0, client_dir)
+import setup_modules
+sys.path.pop(0)
+setup_modules.setup(base_path=client_dir,
+ root_module_name="autotest_lib.client")
diff --git a/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/control b/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/control
new file mode 100644
index 0000000..dd3d160
--- /dev/null
+++ b/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/control
@@ -0,0 +1,5 @@
+# Copyright (c) 2013 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.
+
+job.setup_dep(['telemetry_dep'])
diff --git a/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/setup_test_links.sh b/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/setup_test_links.sh
new file mode 100755
index 0000000..17e0a25
--- /dev/null
+++ b/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/setup_test_links.sh
@@ -0,0 +1,18 @@
+#!/bin/bash
+#
+# Copyright (c) 2013 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.
+#
+# This script makes a symlink from the telemetry_dep to the correct place in
+# the chrome_test version of the chrome source tree.
+
+# Return an error code if the chrome_test dep isn't present
+if [ ! -d /usr/local/autotest/deps/chrome_test ] ; then
+ return 1
+fi
+
+if [ ! -e /usr/local/autotest/deps/chrome_test/test_src/data ]; then
+ ln -sf /usr/local/autotest/deps/telemetry_dep/test_src/data \
+ /usr/local/autotest/deps/chrome_test/test_src/data
+fi
diff --git a/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/telemetry_dep.py b/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/telemetry_dep.py
new file mode 100755
index 0000000..d04e6e7
--- /dev/null
+++ b/chrome/test/chromeos/autotest/files/client/deps/telemetry_dep/telemetry_dep.py
@@ -0,0 +1,22 @@
+#!/usr/bin/python
+
+# Copyright (c) 2013 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.
+
+"""Install the telemetry_dep dependency.
+
+This is done by the Chrome ebuild so this in fact has nothing to do.
+"""
+
+import os
+from autotest_lib.client.bin import utils
+
+version = 1
+
+def setup(top_dir):
+ return
+
+
+pwd = os.getcwd()
+utils.update_version(pwd + '/src', False, version, setup, None)