| Index: Tools/Scripts/webkitpy/bindings/main.py
|
| diff --git a/Tools/Scripts/webkitpy/bindings/main.py b/Tools/Scripts/webkitpy/bindings/main.py
|
| index 80d8dc6a23a449c23061cb8e48ef9792dec2cdcd..8a93049ccb9000340312455ef4dc684bff2e053a 100644
|
| --- a/Tools/Scripts/webkitpy/bindings/main.py
|
| +++ b/Tools/Scripts/webkitpy/bindings/main.py
|
| @@ -53,6 +53,7 @@ SKIP_PYTHON = set([
|
| ])
|
|
|
| input_directory = os.path.join('bindings', 'tests', 'idls')
|
| +test_support_input_directory = os.path.join(input_directory, 'test_support')
|
| reference_directory = os.path.join('bindings', 'tests', 'results')
|
| reference_event_names_filename = os.path.join(reference_directory, 'EventInterfaces.in')
|
|
|
| @@ -86,6 +87,7 @@ class BindingsTests(object):
|
| self.reset_results = reset_results
|
| self.executive = executive
|
| _, self.interface_dependencies_filename = provider.newtempfile()
|
| + _, self.test_support_interface_dependencies_filename = provider.newtempfile()
|
| if reset_results:
|
| self.event_names_filename = os.path.join(reference_directory, 'EventInterfaces.in')
|
| else:
|
| @@ -104,6 +106,7 @@ class BindingsTests(object):
|
| '--include', '.',
|
| '--outputDir', output_directory,
|
| '--interfaceDependenciesFile', self.interface_dependencies_filename,
|
| + '--testSupportInterfaceDependenciesFile', self.test_support_interface_dependencies_filename,
|
| '--idlAttributesFile', 'bindings/scripts/IDLAttributes.txt',
|
| idl_file]
|
| try:
|
| @@ -142,6 +145,14 @@ class BindingsTests(object):
|
| for idl_path in idl_paths)
|
| os.write(idl_files_list_file, idl_files_list_contents)
|
|
|
| + test_support_idl_files_list_file, test_support_idl_files_list_filename = provider.newtempfile()
|
| + test_support_idl_paths = [os.path.join(test_support_input_directory, input_file)
|
| + for input_file in os.listdir(test_support_input_directory)
|
| + if input_file.endswith('.idl')]
|
| + test_support_idl_files_list_contents = ''.join(test_support_idl_paths + '\n'
|
| + for test_support_idl_paths in test_support_idl_paths)
|
| + os.write(test_support_idl_files_list_file, test_support_idl_files_list_contents)
|
| +
|
| # Dummy files, required by compute_dependencies but not checked
|
| _, window_constructors_file = provider.newtempfile()
|
| _, workerglobalscope_constructors_file = provider.newtempfile()
|
| @@ -151,6 +162,8 @@ class BindingsTests(object):
|
| 'bindings/scripts/compute_dependencies.py',
|
| '--idl-files-list', idl_files_list_filename,
|
| '--interface-dependencies-file', self.interface_dependencies_filename,
|
| + '--test-support-idl-files-list', test_support_idl_files_list_filename,
|
| + '--test-support-interface-dependencies-file', self.test_support_interface_dependencies_filename,
|
| '--window-constructors-file', window_constructors_file,
|
| '--workerglobalscope-constructors-file', workerglobalscope_constructors_file,
|
| '--sharedworkerglobalscope-constructors-file', sharedworkerglobalscope_constructors_file,
|
| @@ -199,7 +212,7 @@ class BindingsTests(object):
|
| for (reference_filename, work_filename) in file_pairs])
|
|
|
| def run_tests(self):
|
| - def generate_and_check_output_pl(idl_filename):
|
| + def generate_and_check_output_pl(idl_filename, input_directory):
|
| # Generate output into the reference directory if resetting
|
| # results, or a temp directory if not.
|
| if self.reset_results:
|
| @@ -230,9 +243,12 @@ class BindingsTests(object):
|
| else:
|
| passed = self.identical_file(reference_event_names_filename,
|
| self.event_names_filename)
|
| - passed &= all([generate_and_check_output_pl(input_file)
|
| + passed &= all([generate_and_check_output_pl(input_file, input_directory)
|
| for input_file in os.listdir(input_directory)
|
| if input_file.endswith('.idl')])
|
| + passed &= all([generate_and_check_output_pl(input_file, test_support_input_directory)
|
| + for input_file in os.listdir(test_support_input_directory)
|
| + if input_file.endswith('.idl')])
|
| print
|
| print 'Python:'
|
| passed &= all([generate_and_check_output_py(input_file)
|
|
|