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

Side by Side Diff: PRESUBMIT_test.py

Issue 2866163002: Update stability report dumper so it handles non-postmortem minidumps (Closed)
Patch Set: presubmit changes Created 3 years, 7 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
« no previous file with comments | « PRESUBMIT.py ('k') | components/browser_watcher/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 import os.path 6 import os.path
7 import re 7 import re
8 import subprocess 8 import subprocess
9 import unittest 9 import unittest
10 10
(...skipping 484 matching lines...) Expand 10 before | Expand all | Expand 10 after
495 }, 495 },
496 } 496 }
497 497
498 new_include_rules = [ 498 new_include_rules = [
499 '-ash', 499 '-ash',
500 '+base', 500 '+base',
501 '+chrome', 501 '+chrome',
502 '+components', 502 '+components',
503 '+content', 503 '+content',
504 '+grit', 504 '+grit',
505 '+grit/generated_resources.h",', 505 '+grit/generated_resources.h",',
manzagop (departed) 2017/05/09 14:16:46 Quick validation: is the ", expected there? Same i
506 '+grit/",', 506 '+grit/",',
507 '+jni/fooblat.h', 507 '+jni/fooblat.h',
508 '+policy', 508 '+policy',
509 '+third_party/WebKit', 509 '+' + os.path.join('third_party', 'WebKit'),
510 ] 510 ]
511 new_specific_include_rules = { 511 new_specific_include_rules = {
512 'compositor\.*': { 512 'compositor\.*': {
513 '+cc', 513 '+cc',
514 }, 514 },
515 'widget\.*': { 515 'widget\.*': {
516 '+gpu', 516 '+gpu',
517 }, 517 },
518 } 518 }
519 519
520 expected = set([ 520 expected = set([
521 'chrome/DEPS', 521 os.path.join('chrome', 'DEPS'),
522 'gpu/DEPS', 522 os.path.join('gpu', 'DEPS'),
523 'components/DEPS', 523 os.path.join('components', 'DEPS'),
524 'policy/DEPS', 524 os.path.join('policy', 'DEPS'),
525 'third_party/WebKit/DEPS', 525 os.path.join('third_party', 'WebKit', 'DEPS'),
526 ]) 526 ])
527 self.assertEqual( 527 self.assertEqual(
528 expected, 528 expected,
529 self.calculate(old_include_rules, old_specific_include_rules, 529 self.calculate(old_include_rules, old_specific_include_rules,
530 new_include_rules, new_specific_include_rules)) 530 new_include_rules, new_specific_include_rules))
531 531
532 def testCalculateAddedDepsIgnoresPermutations(self): 532 def testCalculateAddedDepsIgnoresPermutations(self):
533 old_include_rules = [ 533 old_include_rules = [
534 '+base', 534 '+base',
535 '+chrome', 535 '+chrome',
(...skipping 797 matching lines...) Expand 10 before | Expand all | Expand 10 after
1333 mock_input_api.files = [ 1333 mock_input_api.files = [
1334 MockAffectedFile('chrome/browser/resources/blah.js', 'arrow => OK here'), 1334 MockAffectedFile('chrome/browser/resources/blah.js', 'arrow => OK here'),
1335 ] 1335 ]
1336 warnings = PRESUBMIT._CheckForRiskyJsFeatures( 1336 warnings = PRESUBMIT._CheckForRiskyJsFeatures(
1337 mock_input_api, MockOutputApi()) 1337 mock_input_api, MockOutputApi())
1338 self.assertEqual(0, len(warnings)) 1338 self.assertEqual(0, len(warnings))
1339 1339
1340 1340
1341 if __name__ == '__main__': 1341 if __name__ == '__main__':
1342 unittest.main() 1342 unittest.main()
OLDNEW
« no previous file with comments | « PRESUBMIT.py ('k') | components/browser_watcher/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698