|
@@ 203-214 (lines=12) @@
|
| 200 |
|
# # false positive : IUTEST_COND_LIKELY/IUTEST_COND_UNLIKELY |
| 201 |
|
# # self.assertFalse('-Wmisleading-indentation' in output) |
| 202 |
|
|
| 203 |
|
def test_make_run(self): |
| 204 |
|
if 'SCRUTINIZER' in os.environ: |
| 205 |
|
self.skipTest('this test is not run on SCRUTINIZER.') |
| 206 |
|
sys.argv[1:] = [test_src] |
| 207 |
|
sys.argv.extend(test_opt) |
| 208 |
|
sys.argv.extend(['--make']) |
| 209 |
|
print(sys.argv) |
| 210 |
|
with self.assertRaises(SystemExit) as cm: |
| 211 |
|
iuwandbox.main() |
| 212 |
|
output = self.dump() |
| 213 |
|
self.assertEqual(cm.exception.code, 0, output) |
| 214 |
|
self.assertRegex(output, r'\[ \s+OK \]') |
| 215 |
|
|
| 216 |
|
|
| 217 |
|
if __name__ == "__main__": |
|
@@ 164-175 (lines=12) @@
|
| 161 |
|
self.assertRegex(output, '.*hint:.*') |
| 162 |
|
self.assertRegex(output, '.*If you do not use boost test, please specify the file with the main function first..*') |
| 163 |
|
|
| 164 |
|
def test_run(self): |
| 165 |
|
if 'SCRUTINIZER' in os.environ: |
| 166 |
|
self.skipTest('this test is not run on SCRUTINIZER.') |
| 167 |
|
sys.argv[1:] = [test_src] |
| 168 |
|
sys.argv.extend(test_opt) |
| 169 |
|
print(sys.argv) |
| 170 |
|
with self.assertRaises(SystemExit) as cm: |
| 171 |
|
iuwandbox.main() |
| 172 |
|
output = self.dump() |
| 173 |
|
self.assertEqual(cm.exception.code, 0, output) |
| 174 |
|
self.assertRegex(output, r'\[ \s+OK \]') |
| 175 |
|
self.assertFalse('-Wmisleading-indentation' in output) |
| 176 |
|
|
| 177 |
|
def test_same_filename(self): |
| 178 |
|
sys.argv[1:] = ['src/main.cpp', 'src/A/sample.cpp', 'src/B/sample.cpp'] |