Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(761)

Side by Side Diff: third_party/WebKit/Tools/Scripts/webkitpy/w3c/test_converter_unittest.py

Issue 2329263002: Run format-webkitpy and fix long lines. (Closed)
Patch Set: Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 206 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 test_html = """<html> 217 test_html = """<html>
218 <head> 218 <head>
219 <script src="../../some-script.js"></script> 219 <script src="../../some-script.js"></script>
220 <style src="../../../some-style.css"></style> 220 <style src="../../../some-style.css"></style>
221 </head> 221 </head>
222 <body> 222 <body>
223 <img src="../../../../some-image.jpg"> 223 <img src="../../../../some-image.jpg">
224 </body> 224 </body>
225 </html> 225 </html>
226 """ 226 """
227 test_reference_support_info = {'reference_relpath': '../', 'files': [ 227 test_reference_support_info = {
228 '../../some-script.js', '../../../some-style.css', '../../../../some -image.jpg'], 'elements': ['script', 'style', 'img']} 228 'reference_relpath': '../',
229 'files': ['../../some-script.js', '../../../some-style.css', '../../ ../../some-image.jpg'],
230 'elements': ['script', 'style', 'img']
231 }
229 converter = _W3CTestConverter(DUMMY_PATH, DUMMY_FILENAME, test_reference _support_info) 232 converter = _W3CTestConverter(DUMMY_PATH, DUMMY_FILENAME, test_reference _support_info)
230 233
231 oc = OutputCapture() 234 oc = OutputCapture()
232 oc.capture_output() 235 oc.capture_output()
233 236
234 try: 237 try:
235 converter.feed(test_html) 238 converter.feed(test_html)
236 converter.close() 239 converter.close()
237 converted = converter.output() 240 converted = converter.output()
238 finally: 241 finally:
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
298 test_html = """<FONT></FONT>""" 301 test_html = """<FONT></FONT>"""
299 converter = _W3CTestConverter(DUMMY_PATH, DUMMY_FILENAME, None) 302 converter = _W3CTestConverter(DUMMY_PATH, DUMMY_FILENAME, None)
300 converter.feed(test_html) 303 converter.feed(test_html)
301 self.assertEqual(converter.output(), ([], """<FONT></FONT>""")) 304 self.assertEqual(converter.output(), ([], """<FONT></FONT>"""))
302 305
303 def test_for_comments(self): 306 def test_for_comments(self):
304 test_html = """<!--abc--><!-- foo -->""" 307 test_html = """<!--abc--><!-- foo -->"""
305 converter = _W3CTestConverter(DUMMY_PATH, DUMMY_FILENAME, None) 308 converter = _W3CTestConverter(DUMMY_PATH, DUMMY_FILENAME, None)
306 converter.feed(test_html) 309 converter.feed(test_html)
307 self.assertEqual(converter.output(), ([], """<!--abc--><!-- foo -->""")) 310 self.assertEqual(converter.output(), ([], """<!--abc--><!-- foo -->"""))
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698