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

Side by Side Diff: Tools/Scripts/webkitpy/style/patchreader_unittest.py

Issue 478553002: Remove thirdparty/unittest2 from webkitpy and require python2.7. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 4 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 | Annotate | Revision Log
OLDNEW
1 # Copyright (C) 2010 Google Inc. All rights reserved. 1 # Copyright (C) 2010 Google Inc. All rights reserved.
2 # Copyright (C) 2009 Torch Mobile Inc. 2 # Copyright (C) 2009 Torch Mobile Inc.
3 # Copyright (C) 2009 Apple Inc. All rights reserved. 3 # Copyright (C) 2009 Apple Inc. All rights reserved.
4 # Copyright (C) 2010 Chris Jerdonek (chris.jerdonek@gmail.com) 4 # Copyright (C) 2010 Chris Jerdonek (chris.jerdonek@gmail.com)
5 # 5 #
6 # Redistribution and use in source and binary forms, with or without 6 # Redistribution and use in source and binary forms, with or without
7 # modification, are permitted provided that the following conditions are 7 # modification, are permitted provided that the following conditions are
8 # met: 8 # met:
9 # 9 #
10 # * Redistributions of source code must retain the above copyright 10 # * Redistributions of source code must retain the above copyright
(...skipping 11 matching lines...) Expand all
22 # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR 22 # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
23 # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT 23 # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
24 # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, 24 # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
25 # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 25 # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
26 # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 26 # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27 # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 27 # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28 # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 28 # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 29 # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 30 # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31 31
32 import webkitpy.thirdparty.unittest2 as unittest 32 import unittest
33 33
34 from webkitpy.common.system.filesystem_mock import MockFileSystem 34 from webkitpy.common.system.filesystem_mock import MockFileSystem
35 from webkitpy.style.patchreader import PatchReader 35 from webkitpy.style.patchreader import PatchReader
36 36
37 37
38 class PatchReaderTest(unittest.TestCase): 38 class PatchReaderTest(unittest.TestCase):
39 39
40 """Test the PatchReader class.""" 40 """Test the PatchReader class."""
41 41
42 class MockTextFileReader(object): 42 class MockTextFileReader(object):
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 92
93 def test_check_patch_with_png_deletion(self): 93 def test_check_patch_with_png_deletion(self):
94 fs = MockFileSystem() 94 fs = MockFileSystem()
95 diff_text = """Index: LayoutTests/platform/mac/foo-expected.png 95 diff_text = """Index: LayoutTests/platform/mac/foo-expected.png
96 =================================================================== 96 ===================================================================
97 Cannot display: file marked as a binary type. 97 Cannot display: file marked as a binary type.
98 svn:mime-type = image/png 98 svn:mime-type = image/png
99 """ 99 """
100 self._patch_checker.check(diff_text, fs) 100 self._patch_checker.check(diff_text, fs)
101 self._assert_checked([], 1) 101 self._assert_checked([], 1)
OLDNEW
« no previous file with comments | « Tools/Scripts/webkitpy/style/optparser_unittest.py ('k') | Tools/Scripts/webkitpy/test/finder_unittest.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698