| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 | 2 |
| 3 # Copyright (c) 2014 Google Inc. All rights reserved. | 3 # Copyright (c) 2014 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 """ | 7 """ |
| 8 Verifies that ios watch extensions and apps are built correctly. | 8 Verifies that ios watch extensions and apps are built correctly. |
| 9 """ | 9 """ |
| 10 | 10 |
| 11 from __future__ import print_function |
| 12 |
| 11 import TestGyp | 13 import TestGyp |
| 12 import TestMac | 14 import TestMac |
| 13 | 15 |
| 14 import sys | 16 import sys |
| 15 | 17 |
| 16 if sys.platform == 'darwin': | 18 if sys.platform == 'darwin': |
| 17 print "This test is currently disabled: https://crbug.com/483696." | 19 print("This test is currently disabled: https://crbug.com/483696.") |
| 18 sys.exit(0) | 20 sys.exit(0) |
| 19 | 21 |
| 20 | 22 |
| 21 if sys.platform == 'darwin' and TestMac.Xcode.Version() >= "0620": | 23 if sys.platform == 'darwin' and TestMac.Xcode.Version() >= "0620": |
| 22 test = TestGyp.TestGyp(formats=['ninja', 'xcode']) | 24 test = TestGyp.TestGyp(formats=['ninja', 'xcode']) |
| 23 | 25 |
| 24 test.run_gyp('watch.gyp', chdir='watch') | 26 test.run_gyp('watch.gyp', chdir='watch') |
| 25 | 27 |
| 26 test.build( | 28 test.build( |
| 27 'watch.gyp', | 29 'watch.gyp', |
| 28 'WatchContainer', | 30 'WatchContainer', |
| 29 chdir='watch') | 31 chdir='watch') |
| 30 | 32 |
| 31 # Test that the extension exists | 33 # Test that the extension exists |
| 32 test.built_file_must_exist( | 34 test.built_file_must_exist( |
| 33 'WatchContainer.app/PlugIns/WatchKitExtension.appex', | 35 'WatchContainer.app/PlugIns/WatchKitExtension.appex', |
| 34 chdir='watch') | 36 chdir='watch') |
| 35 | 37 |
| 36 # Test that the watch app exists | 38 # Test that the watch app exists |
| 37 test.built_file_must_exist( | 39 test.built_file_must_exist( |
| 38 'WatchContainer.app/PlugIns/WatchKitExtension.appex/WatchApp.app', | 40 'WatchContainer.app/PlugIns/WatchKitExtension.appex/WatchApp.app', |
| 39 chdir='watch') | 41 chdir='watch') |
| 40 | 42 |
| 41 test.pass_test() | 43 test.pass_test() |
| 42 | 44 |
| OLD | NEW |