summaryrefslogtreecommitdiffstats
path: root/third_party/python/gyp/test/rules/gyptest-input-root.py
diff options
context:
space:
mode:
Diffstat (limited to 'third_party/python/gyp/test/rules/gyptest-input-root.py')
-rwxr-xr-xthird_party/python/gyp/test/rules/gyptest-input-root.py26
1 files changed, 26 insertions, 0 deletions
diff --git a/third_party/python/gyp/test/rules/gyptest-input-root.py b/third_party/python/gyp/test/rules/gyptest-input-root.py
new file mode 100755
index 0000000000..92bade6d48
--- /dev/null
+++ b/third_party/python/gyp/test/rules/gyptest-input-root.py
@@ -0,0 +1,26 @@
+#!/usr/bin/env python
+
+# Copyright (c) 2011 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 RULE_INPUT_ROOT isn't turned into a path in rule actions
+"""
+
+import TestGyp
+
+test = TestGyp.TestGyp()
+
+test.run_gyp('input-root.gyp', chdir='src')
+
+test.relocate('src', 'relocate/src')
+
+test.build('input-root.gyp', target='test', chdir='relocate/src')
+
+expect = """\
+Hello somefile
+"""
+
+test.run_built_executable('test', chdir='relocate/src', stdout=expect)
+test.pass_test()