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

Side by Side Diff: tools/test.py

Issue 119239: Add a check to presubmit.py linting python and SCons files for trailing white... Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 6 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
« no previous file with comments | « tools/presubmit.py ('k') | no next file » | 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 # 2 #
3 # Copyright 2008 the V8 project authors. All rights reserved. 3 # Copyright 2008 the V8 project authors. All rights reserved.
4 # Redistribution and use in source and binary forms, with or without 4 # Redistribution and use in source and binary forms, with or without
5 # modification, are permitted provided that the following conditions are 5 # modification, are permitted provided that the following conditions are
6 # met: 6 # met:
7 # 7 #
8 # * Redistributions of source code must retain the above copyright 8 # * Redistributions of source code must retain the above copyright
9 # notice, this list of conditions and the following disclaimer. 9 # notice, this list of conditions and the following disclaimer.
10 # * Redistributions in binary form must reproduce the above 10 # * Redistributions in binary form must reproduce the above
(...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after
383 return 0x80000000 & self.output.exit_code and not (0x3FFFFF00 & self.outpu t.exit_code) 383 return 0x80000000 & self.output.exit_code and not (0x3FFFFF00 & self.outpu t.exit_code)
384 else: 384 else:
385 # Timed out tests will have exit_code -signal.SIGTERM. 385 # Timed out tests will have exit_code -signal.SIGTERM.
386 if self.output.timed_out: 386 if self.output.timed_out:
387 return False 387 return False
388 return self.output.exit_code < 0 and \ 388 return self.output.exit_code < 0 and \
389 self.output.exit_code != -signal.SIGABRT 389 self.output.exit_code != -signal.SIGABRT
390 390
391 def HasTimedOut(self): 391 def HasTimedOut(self):
392 return self.output.timed_out; 392 return self.output.timed_out;
393 393
394 def HasFailed(self): 394 def HasFailed(self):
395 execution_failed = self.test.DidFail(self.output) 395 execution_failed = self.test.DidFail(self.output)
396 if self.test.IsNegative(): 396 if self.test.IsNegative():
397 return not execution_failed 397 return not execution_failed
398 else: 398 else:
399 return execution_failed 399 return execution_failed
400 400
401 401
402 def KillProcessWithID(pid): 402 def KillProcessWithID(pid):
403 if utils.IsWindows(): 403 if utils.IsWindows():
(...skipping 927 matching lines...) Expand 10 before | Expand all | Expand 10 after
1331 for entry in timed_tests[:20]: 1331 for entry in timed_tests[:20]:
1332 t = FormatTime(entry.duration) 1332 t = FormatTime(entry.duration)
1333 sys.stderr.write("%4i (%s) %s\n" % (index, t, entry.GetLabel())) 1333 sys.stderr.write("%4i (%s) %s\n" % (index, t, entry.GetLabel()))
1334 index += 1 1334 index += 1
1335 1335
1336 return result 1336 return result
1337 1337
1338 1338
1339 if __name__ == '__main__': 1339 if __name__ == '__main__':
1340 sys.exit(Main()) 1340 sys.exit(Main())
OLDNEW
« no previous file with comments | « tools/presubmit.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698