OLD | NEW |
1 # Copyright (C) 2011 Google Inc. All rights reserved. | 1 # Copyright (C) 2011 Google Inc. All rights reserved. |
2 # | 2 # |
3 # Redistribution and use in source and binary forms, with or without | 3 # Redistribution and use in source and binary forms, with or without |
4 # modification, are permitted provided that the following conditions | 4 # modification, are permitted provided that the following conditions |
5 # are met: | 5 # are met: |
6 # 1. Redistributions of source code must retain the above copyright | 6 # 1. Redistributions of source code must retain the above copyright |
7 # notice, this list of conditions and the following disclaimer. | 7 # notice, this list of conditions and the following disclaimer. |
8 # 2. Redistributions in binary form must reproduce the above copyright | 8 # 2. Redistributions in binary form must reproduce the above copyright |
9 # notice, this list of conditions and the following disclaimer in the | 9 # notice, this list of conditions and the following disclaimer in the |
10 # documentation and/or other materials provided with the distribution. | 10 # documentation and/or other materials provided with the distribution. |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
50 | 50 |
51 def __init__(self, reset_results, executive): | 51 def __init__(self, reset_results, executive): |
52 self.reset_results = reset_results | 52 self.reset_results = reset_results |
53 self.executive = executive | 53 self.executive = executive |
54 | 54 |
55 def generate_from_idl(self, idl_file, output_directory, interface_dependenci
es_file): | 55 def generate_from_idl(self, idl_file, output_directory, interface_dependenci
es_file): |
56 cmd = ['perl', '-w', | 56 cmd = ['perl', '-w', |
57 '-Ibindings/scripts', | 57 '-Ibindings/scripts', |
58 '-Icore/scripts', | 58 '-Icore/scripts', |
59 '-I../../JSON/out/lib/perl5', | 59 '-I../../JSON/out/lib/perl5', |
60 'bindings/scripts/generate-bindings.pl', | 60 'bindings/scripts/deprecated_generate_bindings.pl', |
61 # idl include directories (path relative to generate-bindings.pl) | 61 # idl include directories (path relative to generate-bindings.pl) |
62 '--include', '.', | 62 '--include', '.', |
63 '--outputDir', output_directory, | 63 '--outputDir', output_directory, |
64 '--interfaceDependenciesFile', interface_dependencies_file, | 64 '--interfaceDependenciesFile', interface_dependencies_file, |
65 '--idlAttributesFile', 'bindings/scripts/IDLAttributes.txt', | 65 '--idlAttributesFile', 'bindings/scripts/IDLAttributes.txt', |
66 idl_file] | 66 idl_file] |
67 | 67 |
68 exit_code = 0 | 68 exit_code = 0 |
69 try: | 69 try: |
70 output = self.executive.run_command(cmd) | 70 output = self.executive.run_command(cmd) |
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
203 if not self.run_tests(input_directory, reference_directory, interface_de
pendencies_file, event_names_file): | 203 if not self.run_tests(input_directory, reference_directory, interface_de
pendencies_file, event_names_file): |
204 all_tests_passed = False | 204 all_tests_passed = False |
205 | 205 |
206 print '' | 206 print '' |
207 if all_tests_passed: | 207 if all_tests_passed: |
208 print 'All tests PASS!' | 208 print 'All tests PASS!' |
209 return 0 | 209 return 0 |
210 else: | 210 else: |
211 print 'Some tests FAIL! (To update the reference files, execute "run
-bindings-tests --reset-results")' | 211 print 'Some tests FAIL! (To update the reference files, execute "run
-bindings-tests --reset-results")' |
212 return -1 | 212 return -1 |
OLD | NEW |