| OLD | NEW |
| 1 # Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. | 1 # Copyright (C) 2013 Adobe Systems Incorporated. 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 # | 6 # |
| 7 # 1. Redistributions of source code must retain the above | 7 # 1. Redistributions of source code must retain the above |
| 8 # copyright notice, this list of conditions and the following | 8 # copyright notice, this list of conditions and the following |
| 9 # disclaimer. | 9 # disclaimer. |
| 10 # 2. Redistributions in binary form must reproduce the above | 10 # 2. Redistributions in binary form must reproduce the above |
| (...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 157 def test_ref_test_without_ref_is_skipped(self): | 157 def test_ref_test_without_ref_is_skipped(self): |
| 158 host = MockHost() | 158 host = MockHost() |
| 159 host.filesystem = MockFileSystem(files={ | 159 host.filesystem = MockFileSystem(files={ |
| 160 '/blink/w3c/dir1/my-ref-test.html': '<html><head><link rel="match" h
ref="not-here.html" /></head></html>', | 160 '/blink/w3c/dir1/my-ref-test.html': '<html><head><link rel="match" h
ref="not-here.html" /></head></html>', |
| 161 '/mock-checkout/third_party/WebKit/LayoutTests/W3CImportExpectations
': '', | 161 '/mock-checkout/third_party/WebKit/LayoutTests/W3CImportExpectations
': '', |
| 162 '/mock-checkout/third_party/WebKit/Source/core/css/CSSProperties.in'
: '', | 162 '/mock-checkout/third_party/WebKit/Source/core/css/CSSProperties.in'
: '', |
| 163 }) | 163 }) |
| 164 importer = TestImporter(host, FAKE_SOURCE_REPO_DIR, self.options()) | 164 importer = TestImporter(host, FAKE_SOURCE_REPO_DIR, self.options()) |
| 165 importer.find_importable_tests() | 165 importer.find_importable_tests() |
| 166 self.assertEqual(importer.import_list, []) | 166 self.assertEqual(importer.import_list, []) |
| 167 |
| 168 def test_should_try_to_convert_positive_cases(self): |
| 169 self.assertTrue(TestImporter.should_try_to_convert({}, 'foo.css', 'Layou
tTests/imported/csswg-test/x')) |
| 170 self.assertTrue(TestImporter.should_try_to_convert({}, 'foo.htm', 'Layou
tTests/imported/csswg-test/x')) |
| 171 self.assertTrue(TestImporter.should_try_to_convert({}, 'foo.html', 'Layo
utTests/imported/csswg-test/x')) |
| 172 self.assertTrue(TestImporter.should_try_to_convert({}, 'foo.xht', 'Layou
tTests/imported/csswg-test/x')) |
| 173 self.assertTrue(TestImporter.should_try_to_convert({}, 'foo.xhtml', 'Lay
outTests/imported/csswg-test/x')) |
| 174 |
| 175 def test_should_not_try_to_convert_js_test(self): |
| 176 self.assertFalse(TestImporter.should_try_to_convert({'is_jstest': True},
'foo.html', 'LayoutTests/imported/csswg-test/x')) |
| 177 |
| 178 def test_should_not_try_to_convert_test_in_wpt(self): |
| 179 self.assertFalse(TestImporter.should_try_to_convert({}, 'foo.html', 'Lay
outTests/imported/wpt/foo')) |
| 180 |
| 181 def test_should_not_try_to_convert_other_file_types(self): |
| 182 self.assertFalse(TestImporter.should_try_to_convert({}, 'foo.bar', 'Layo
utTests/imported/csswg-test/x')) |
| 183 self.assertFalse(TestImporter.should_try_to_convert({}, 'foo.js', 'Layou
tTests/imported/csswg-test/x')) |
| 184 self.assertFalse(TestImporter.should_try_to_convert({}, 'foo.md', 'Layou
tTests/imported/csswg-test/x')) |
| 185 self.assertFalse(TestImporter.should_try_to_convert({}, 'foo.png', 'Layo
utTests/imported/csswg-test/x')) |
| 186 self.assertFalse(TestImporter.should_try_to_convert({}, 'foo.svg', 'Layo
utTests/imported/csswg-test/x')) |
| 187 self.assertFalse(TestImporter.should_try_to_convert({}, 'foo.svgz', 'Lay
outTests/imported/csswg-test/x')) |
| OLD | NEW |