| Index: third_party/WebKit/Tools/Scripts/webkitpy/style/checkers/cpp_unittest.py
|
| diff --git a/third_party/WebKit/Tools/Scripts/webkitpy/style/checkers/cpp_unittest.py b/third_party/WebKit/Tools/Scripts/webkitpy/style/checkers/cpp_unittest.py
|
| index 89354f6a21213abb27e177baa3b33e7085179eff..4dcbbc32a169a767ee6e20311dd3eaddf12b4bff 100644
|
| --- a/third_party/WebKit/Tools/Scripts/webkitpy/style/checkers/cpp_unittest.py
|
| +++ b/third_party/WebKit/Tools/Scripts/webkitpy/style/checkers/cpp_unittest.py
|
| @@ -2271,53 +2271,6 @@ class OrderOfIncludesTest(CppStyleTestBase):
|
| self.assertEqual('Found header this file implements after other header.',
|
| self.include_state.check_next_include_order(cpp_style._PRIMARY_HEADER, False, True))
|
|
|
| - def test_check_alphabetical_include_order(self):
|
| - self.assert_language_rules_check('foo.h',
|
| - '#include "a.h"\n'
|
| - '#include "c.h"\n'
|
| - '#include "b.h"\n',
|
| - 'Alphabetical sorting problem. [build/include_order] [4]')
|
| -
|
| - self.assert_language_rules_check('foo.h',
|
| - '#include "a.h"\n'
|
| - '#include "b.h"\n'
|
| - '#include "c.h"\n',
|
| - '')
|
| -
|
| - self.assert_language_rules_check('foo.h',
|
| - '#include <assert.h>\n'
|
| - '#include "bar.h"\n',
|
| - 'Alphabetical sorting problem. [build/include_order] [4]')
|
| -
|
| - self.assert_language_rules_check('foo.h',
|
| - '#include "bar.h"\n'
|
| - '#include <assert.h>\n',
|
| - '')
|
| -
|
| - def test_check_alphabetical_include_order_errors_reported_for_both_lines(self):
|
| - # If one of the two lines of out of order headers are filtered, the error should be
|
| - # reported on the other line.
|
| - self.assert_language_rules_check('foo.h',
|
| - '#include "a.h"\n'
|
| - '#include "c.h"\n'
|
| - '#include "b.h"\n',
|
| - 'Alphabetical sorting problem. [build/include_order] [4]',
|
| - lines_to_check=[2])
|
| -
|
| - self.assert_language_rules_check('foo.h',
|
| - '#include "a.h"\n'
|
| - '#include "c.h"\n'
|
| - '#include "b.h"\n',
|
| - 'Alphabetical sorting problem. [build/include_order] [4]',
|
| - lines_to_check=[3])
|
| -
|
| - # If no lines are filtered, the error should be reported only once.
|
| - self.assert_language_rules_check('foo.h',
|
| - '#include "a.h"\n'
|
| - '#include "c.h"\n'
|
| - '#include "b.h"\n',
|
| - 'Alphabetical sorting problem. [build/include_order] [4]')
|
| -
|
| def test_check_line_break_after_own_header(self):
|
| self.assert_language_rules_check('foo.cpp',
|
| '#include "foo.h"\n'
|
| @@ -2343,38 +2296,6 @@ class OrderOfIncludesTest(CppStyleTestBase):
|
| '#include "bar.h"\n', # No flag because previous is in preprocessor section
|
| '')
|
|
|
| - self.assert_language_rules_check('foo.cpp',
|
| - '#include "foo.h"\n'
|
| - '\n'
|
| - '#ifdef BAZ\n'
|
| - '#include "baz.h"\n'
|
| - '#endif"\n'
|
| - '#include "bar.h"\n'
|
| - '#include "a.h"\n', # Should still flag this.
|
| - 'Alphabetical sorting problem. [build/include_order] [4]')
|
| -
|
| - self.assert_language_rules_check('foo.cpp',
|
| - '#include "foo.h"\n'
|
| - '\n'
|
| - '#ifdef BAZ\n'
|
| - '#include "baz.h"\n'
|
| - '#include "bar.h"\n' # Should still flag this
|
| - '#endif"\n',
|
| - 'Alphabetical sorting problem. [build/include_order] [4]')
|
| -
|
| - self.assert_language_rules_check('foo.cpp',
|
| - '#include "foo.h"\n'
|
| - '\n'
|
| - '#ifdef BAZ\n'
|
| - '#include "baz.h"\n'
|
| - '#endif"\n'
|
| - '#ifdef FOOBAR\n'
|
| - '#include "foobar.h"\n'
|
| - '#endif"\n'
|
| - '#include "bar.h"\n'
|
| - '#include "a.h"\n', # Should still flag this.
|
| - 'Alphabetical sorting problem. [build/include_order] [4]')
|
| -
|
| # Check that after an already included error, the sorting rules still work.
|
| self.assert_language_rules_check('foo.cpp',
|
| '#include "foo.h"\n'
|
| @@ -2418,30 +2339,6 @@ class OrderOfIncludesTest(CppStyleTestBase):
|
|
|
| os.path.isfile = self.os_path_isfile_orig
|
|
|
| - def test_public_primary_header(self):
|
| - # System header is not considered a primary header.
|
| - self.assert_language_rules_check('foo.cpp',
|
| - '#include "config.h"\n'
|
| - '#include <other/foo.h>\n'
|
| - '\n'
|
| - '#include "a.h"\n',
|
| - 'Alphabetical sorting problem. [build/include_order] [4]')
|
| -
|
| - # ...except that it starts with public/.
|
| - self.assert_language_rules_check('foo.cpp',
|
| - '#include <public/foo.h>\n'
|
| - '\n'
|
| - '#include "a.h"\n',
|
| - '')
|
| -
|
| - # Even if it starts with public/ its base part must match with the source file name.
|
| - self.assert_language_rules_check('foo.cpp',
|
| - '#include "config.h"\n'
|
| - '#include <public/foop.h>\n'
|
| - '\n'
|
| - '#include "a.h"\n',
|
| - 'Alphabetical sorting problem. [build/include_order] [4]')
|
| -
|
| def test_check_wtf_includes(self):
|
| self.assert_language_rules_check('foo.cpp',
|
| '#include "foo.h"\n'
|
|
|