summaryrefslogtreecommitdiff
path: root/deps/gyp/test/msvs/external_builder
diff options
context:
space:
mode:
Diffstat (limited to 'deps/gyp/test/msvs/external_builder')
-rw-r--r--deps/gyp/test/msvs/external_builder/external.gyp68
-rw-r--r--deps/gyp/test/msvs/external_builder/external_builder.py9
-rw-r--r--deps/gyp/test/msvs/external_builder/gyptest-all.py59
-rw-r--r--deps/gyp/test/msvs/external_builder/hello.cpp10
-rw-r--r--deps/gyp/test/msvs/external_builder/hello.z6
-rw-r--r--deps/gyp/test/msvs/external_builder/msbuild_action.py9
-rw-r--r--deps/gyp/test/msvs/external_builder/msbuild_rule.py11
7 files changed, 0 insertions, 172 deletions
diff --git a/deps/gyp/test/msvs/external_builder/external.gyp b/deps/gyp/test/msvs/external_builder/external.gyp
deleted file mode 100644
index abe5b5889c..0000000000
--- a/deps/gyp/test/msvs/external_builder/external.gyp
+++ /dev/null
@@ -1,68 +0,0 @@
-# Copyright (c) 2013 Google Inc. All rights reserved.
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-{
- 'variables': {
- # the test driver switches this flag when testing external builder
- 'use_external_builder%': 0,
- },
- 'targets': [
- {
- 'target_name': 'external',
- 'type': 'executable',
- 'sources': [
- 'hello.cpp',
- 'hello.z',
- ],
- 'rules': [
- {
- 'rule_name': 'test_rule',
- 'extension': 'z',
- 'outputs': [
- 'msbuild_rule.out',
- ],
- 'action': [
- 'python',
- 'msbuild_rule.py',
- '<(RULE_INPUT_PATH)',
- 'a', 'b', 'c',
- ],
- 'msvs_cygwin_shell': 0,
- },
- ],
- 'actions': [
- {
- 'action_name': 'test action',
- 'inputs': [
- 'msbuild_action.py',
- ],
- 'outputs': [
- 'msbuild_action.out',
- ],
- 'action': [
- 'python',
- '<@(_inputs)',
- 'x', 'y', 'z',
- ],
- 'msvs_cygwin_shell': 0,
- },
- ],
- 'conditions': [
- ['use_external_builder==1', {
- 'msvs_external_builder': 'test',
- 'msvs_external_builder_build_cmd': [
- 'python',
- 'external_builder.py',
- 'build', '1', '2', '3',
- ],
- 'msvs_external_builder_clean_cmd': [
- 'python',
- 'external_builder.py',
- 'clean', '4', '5',
- ],
- }],
- ],
- },
- ],
-}
diff --git a/deps/gyp/test/msvs/external_builder/external_builder.py b/deps/gyp/test/msvs/external_builder/external_builder.py
deleted file mode 100644
index ddfc1e5e33..0000000000
--- a/deps/gyp/test/msvs/external_builder/external_builder.py
+++ /dev/null
@@ -1,9 +0,0 @@
-# Copyright (c) 2013 Google Inc. All rights reserved.
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-import sys
-
-with open('external_builder.out', 'w') as f:
- f.write(' '.join(sys.argv))
-
diff --git a/deps/gyp/test/msvs/external_builder/gyptest-all.py b/deps/gyp/test/msvs/external_builder/gyptest-all.py
deleted file mode 100644
index 72faa7ab7f..0000000000
--- a/deps/gyp/test/msvs/external_builder/gyptest-all.py
+++ /dev/null
@@ -1,59 +0,0 @@
-#!/usr/bin/env python
-
-# Copyright (c) 2013 Google Inc. All rights reserved.
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-"""
-Verifies that msvs_external_builder being set will invoke the provided
-msvs_external_builder_build_cmd and msvs_external_builder_clean_cmd, and will
-not invoke MSBuild actions and rules.
-"""
-
-import os
-import sys
-import TestGyp
-
-if int(os.environ.get('GYP_MSVS_VERSION', 0)) < 2010:
- sys.exit(0)
-
-test = TestGyp.TestGyp(formats=['msvs'], workdir='workarea_all')
-
-# without the flag set
-test.run_gyp('external.gyp')
-test.build('external.gyp', target='external')
-test.must_not_exist('external_builder.out')
-test.must_exist('msbuild_rule.out')
-test.must_exist('msbuild_action.out')
-test.must_match('msbuild_rule.out', 'msbuild_rule.py hello.z a b c')
-test.must_match('msbuild_action.out', 'msbuild_action.py x y z')
-os.remove('msbuild_rule.out')
-os.remove('msbuild_action.out')
-
-# with the flag set, using Build
-try:
- os.environ['GYP_DEFINES'] = 'use_external_builder=1'
- test.run_gyp('external.gyp')
- test.build('external.gyp', target='external')
-finally:
- del os.environ['GYP_DEFINES']
-test.must_not_exist('msbuild_rule.out')
-test.must_not_exist('msbuild_action.out')
-test.must_exist('external_builder.out')
-test.must_match('external_builder.out', 'external_builder.py build 1 2 3')
-os.remove('external_builder.out')
-
-# with the flag set, using Clean
-try:
- os.environ['GYP_DEFINES'] = 'use_external_builder=1'
- test.run_gyp('external.gyp')
- test.build('external.gyp', target='external', clean=True)
-finally:
- del os.environ['GYP_DEFINES']
-test.must_not_exist('msbuild_rule.out')
-test.must_not_exist('msbuild_action.out')
-test.must_exist('external_builder.out')
-test.must_match('external_builder.out', 'external_builder.py clean 4 5')
-os.remove('external_builder.out')
-
-test.pass_test()
diff --git a/deps/gyp/test/msvs/external_builder/hello.cpp b/deps/gyp/test/msvs/external_builder/hello.cpp
deleted file mode 100644
index bc0c0265b5..0000000000
--- a/deps/gyp/test/msvs/external_builder/hello.cpp
+++ /dev/null
@@ -1,10 +0,0 @@
-// Copyright (c) 2012 Google Inc. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include <stdio.h>
-
-int main(void) {
- printf("Hello, world!\n");
- return 0;
-}
diff --git a/deps/gyp/test/msvs/external_builder/hello.z b/deps/gyp/test/msvs/external_builder/hello.z
deleted file mode 100644
index aa478827b5..0000000000
--- a/deps/gyp/test/msvs/external_builder/hello.z
+++ /dev/null
@@ -1,6 +0,0 @@
-# Copyright (c) 2013 Google Inc. All rights reserved.
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-This file will be passed to the test rule.
-
diff --git a/deps/gyp/test/msvs/external_builder/msbuild_action.py b/deps/gyp/test/msvs/external_builder/msbuild_action.py
deleted file mode 100644
index 632d786922..0000000000
--- a/deps/gyp/test/msvs/external_builder/msbuild_action.py
+++ /dev/null
@@ -1,9 +0,0 @@
-# Copyright (c) 2013 Google Inc. All rights reserved.
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-import sys
-
-with open('msbuild_action.out', 'w') as f:
- f.write(' '.join(sys.argv))
-
diff --git a/deps/gyp/test/msvs/external_builder/msbuild_rule.py b/deps/gyp/test/msvs/external_builder/msbuild_rule.py
deleted file mode 100644
index 0d6e315775..0000000000
--- a/deps/gyp/test/msvs/external_builder/msbuild_rule.py
+++ /dev/null
@@ -1,11 +0,0 @@
-# Copyright (c) 2013 Google Inc. All rights reserved.
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-import sys, os.path
-
-sys.argv[1] = os.path.basename(sys.argv[1])
-
-with open('msbuild_rule.out', 'w') as f:
- f.write(' '.join(sys.argv))
-