summaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authormaruel@chromium.org <maruel@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-03-09 21:49:49 +0000
committermaruel@chromium.org <maruel@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-03-09 21:49:49 +0000
commitf052627beff1751ff49c9197ef9e1054180fae4f (patch)
tree4e2adb601eee9cc318f49655f5fc4faa7972278f /net
parent1822366e00de35ad014c6e76249be7d2a2d067f5 (diff)
downloadchromium_src-f052627beff1751ff49c9197ef9e1054180fae4f.zip
chromium_src-f052627beff1751ff49c9197ef9e1054180fae4f.tar.gz
chromium_src-f052627beff1751ff49c9197ef9e1054180fae4f.tar.bz2
Add net_unittests_run.
This permits running net_unittests outside a chromium checkout. R=cbentzel@chromium.org BUG=98834 TEST= Review URL: http://codereview.chromium.org/9648019 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@125914 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net')
-rw-r--r--net/net.gyp67
1 files changed, 67 insertions, 0 deletions
diff --git a/net/net.gyp b/net/net.gyp
index c719d12..850a522 100644
--- a/net/net.gyp
+++ b/net/net.gyp
@@ -1343,6 +1343,73 @@
],
},
{
+ 'target_name': 'net_unittests_run',
+ 'type': 'none',
+ 'dependencies': [
+ 'net_unittests',
+ ],
+ 'actions': [
+ {
+ 'action_name': 'response_file',
+ 'inputs': [
+ '<(PRODUCT_DIR)/net_unittests<(EXECUTABLE_SUFFIX)',
+ '<(DEPTH)/testing/test_env.py',
+ '<(DEPTH)/testing/xvfb.py',
+ '<(DEPTH)/third_party/pyftpdlib/src/pyftpdlib/__init__.py',
+ '<(DEPTH)/third_party/pyftpdlib/src/pyftpdlib/ftpserver.py',
+ ],
+ 'conditions': [
+ ['OS=="linux"', {
+ 'inputs': [
+ '<(PRODUCT_DIR)/xdisplaycheck<(EXECUTABLE_SUFFIX)',
+ ],
+ }],
+ ],
+ 'outputs': [
+ '<(PRODUCT_DIR)/net_unittests.inputs',
+ ],
+ 'action': [
+ 'python',
+ '-c',
+ 'import sys; '
+ 'open(sys.argv[1], \'w\').write(\'\\n\'.join(sys.argv[2:]))',
+ '<@(_outputs)',
+ '<@(_inputs)',
+ ],
+ },
+ {
+ 'action_name': 'isolate',
+ 'inputs': [
+ '<(PRODUCT_DIR)/net_unittests.inputs',
+ ],
+ 'outputs': [
+ '<(PRODUCT_DIR)/net_unittests.results',
+ ],
+ 'action': [
+ 'python',
+ '<(DEPTH)/tools/isolate/isolate.py',
+ '--mode=<(tests_run)',
+ '--root', '<(DEPTH)',
+ '--result', '<@(_outputs)',
+ '--files', '<@(_inputs)',
+ # Directories can't be tracked by build tools (make, msbuild, xcode,
+ # etc) so we just put it on the command line without specifying it
+ # as an input.
+ # TODO(maruel): Revisit the support for this at all and list each
+ # individual test files instead.
+ 'data/',
+ 'tools/testserver/',
+ '<(DEPTH)/third_party/tlslite/tlslite/',
+ '--',
+ # Wraps net_unittests under xvfb.
+ '<(DEPTH)/testing/xvfb.py',
+ '<(PRODUCT_DIR)',
+ '<(PRODUCT_DIR)/net_unittests<(EXECUTABLE_SUFFIX)',
+ ],
+ },
+ ],
+ },
+ {
'target_name': 'net_perftests',
'type': 'executable',
'dependencies': [