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

Side by Side Diff: test/sibling/gyptest-all.py

Issue 421453003: Add TestGypXcodeNinja to run tests against the xcode-ninja generator (Closed) Base URL: https://chromium.googlesource.com/external/gyp.git@master
Patch Set: Rebase onto origin/master Created 6 years 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 unified diff | Download patch
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 2
3 # Copyright (c) 2012 Google Inc. All rights reserved. 3 # Copyright (c) 2012 Google Inc. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 import TestGyp 7 import TestGyp
8 8
9 test = TestGyp.TestGyp() 9 test = TestGyp.TestGyp()
10 10
11 # The xcode-ninja generator handles gypfiles which are not at the
12 # project root incorrectly.
13 # cf. https://code.google.com/p/gyp/issues/detail?id=460
14 if test.format == 'xcode-ninja':
15 test.skip_test()
16
11 test.run_gyp('build/all.gyp', chdir='src') 17 test.run_gyp('build/all.gyp', chdir='src')
12 18
13 test.build('build/all.gyp', test.ALL, chdir='src') 19 test.build('build/all.gyp', test.ALL, chdir='src')
14 20
15 chdir = 'src/build' 21 chdir = 'src/build'
16 22
17 # The top-level Makefile is in the directory where gyp was run. 23 # The top-level Makefile is in the directory where gyp was run.
18 # TODO(mmoss) Should the Makefile go in the directory of the passed in .gyp 24 # TODO(mmoss) Should the Makefile go in the directory of the passed in .gyp
19 # file? What about when passing in multiple .gyp files? Would sub-project 25 # file? What about when passing in multiple .gyp files? Would sub-project
20 # Makefiles (see http://codereview.chromium.org/340008 comments) solve this? 26 # Makefiles (see http://codereview.chromium.org/340008 comments) solve this?
21 if test.format in ('make', 'ninja', 'cmake'): 27 if test.format in ('make', 'ninja', 'cmake'):
22 chdir = 'src' 28 chdir = 'src'
23 29
24 if test.format == 'xcode': 30 if test.format == 'xcode':
25 chdir = 'src/prog1' 31 chdir = 'src/prog1'
26 test.run_built_executable('program1', 32 test.run_built_executable('program1',
27 chdir=chdir, 33 chdir=chdir,
28 stdout="Hello from prog1.c\n") 34 stdout="Hello from prog1.c\n")
29 35
30 if test.format == 'xcode': 36 if test.format == 'xcode':
31 chdir = 'src/prog2' 37 chdir = 'src/prog2'
32 test.run_built_executable('program2', 38 test.run_built_executable('program2',
33 chdir=chdir, 39 chdir=chdir,
34 stdout="Hello from prog2.c\n") 40 stdout="Hello from prog2.c\n")
35 41
36 test.pass_test() 42 test.pass_test()
OLDNEW
« no previous file with comments | « test/same-target-name-different-directory/gyptest-all.py ('k') | test/sibling/gyptest-relocate.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698