Index: mojo/PRESUBMIT_test.py |
diff --git a/mojo/PRESUBMIT_test.py b/mojo/PRESUBMIT_test.py |
index 5245b68bb2a4841c09ef6b144e3b28d661d9e64e..c2a31b217b53577a5f8174927ecb6bd7f76c7ac8 100755 |
--- a/mojo/PRESUBMIT_test.py |
+++ b/mojo/PRESUBMIT_test.py |
@@ -201,6 +201,15 @@ class SourceSetTypesInBuildFilesTest(unittest.TestCase): |
self.assertEqual(1, len(warnings)) |
self.checkWarningWithSingleItem(warnings[0], 'SDK', _SDK_BUILD_FILE, 2) |
+ def testPythonSourceSetInSDKBuildFile(self): |
+ """Tests that a source_set within an SDK buildfile is flagged.""" |
qsr
2014/12/17 12:17:39
Comment seems to be off.
etiennej
2014/12/17 12:19:39
Sorry, fixed.
|
+ mock_input_api = self.inputApiContainingFileWithSourceSets( |
+ _SDK_BUILD_FILE, |
+ [ 'mojo_sdk_source_set(', 'python_binary_source_set(' ]) |
+ warnings = PRESUBMIT._BuildFileChecks(mock_input_api, MockOutputApi()) |
+ |
+ self.assertEqual(0, len(warnings)) |
+ |
def testEDKSourceSetInSDKBuildFile(self): |
"""Tests that a mojo_edk_source_set within an SDK buildfile is flagged.""" |
mock_input_api = self.inputApiContainingFileWithSourceSets( |