| OLD | NEW |
| 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 String getProcessTestFileName() { | 5 String getProcessTestFileName() { |
| 6 var names = ['out/Release_ia32/process_test', | 6 var os = new Platform().operatingSystem(); |
| 7 'out/Debug_ia32/process_test', | 7 |
| 8 'xcodebuild/Release_ia32/process_test', | 8 var outDir = ''; |
| 9 'xcodebuild/Debug_ia32/process_test', | 9 if (os == 'linux') { |
| 10 'Release_ia32/process_test.exe', | 10 outDir = 'out'; |
| 11 'Debug_ia32/process_test.exe']; | 11 } else if (os == 'macos') { |
| 12 outDir = 'xcodebuild'; |
| 13 } |
| 14 |
| 15 var names = ['$outDir/Release_ia32/process_test', |
| 16 '$outDir/Debug_ia32/process_test']; |
| 17 |
| 12 for (var name in names) { | 18 for (var name in names) { |
| 13 if (new File(name).existsSync()) { | 19 if (new File(name).existsSync()) { |
| 14 return name; | 20 return name; |
| 15 } | 21 } |
| 16 } | 22 } |
| 23 |
| 17 Expect.fail('Could not find the process_test program.'); | 24 Expect.fail('Could not find the process_test program.'); |
| 18 } | 25 } |
| OLD | NEW |