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

Side by Side Diff: appengine/findit/test/findit_api_test.py

Issue 2480483002: [Findit] fix bug when display confidence score on SoM. (Closed)
Patch Set: remove print statements. Created 4 years, 1 month 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 | « appengine/findit/findit_api.py ('k') | appengine/findit/waterfall/suspected_cl_util.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2015 The Chromium Authors. All rights reserved. 1 # Copyright 2015 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import json 5 import json
6 import mock 6 import mock
7 import pickle 7 import pickle
8 import re 8 import re
9 9
10 from google.appengine.api import taskqueue 10 from google.appengine.api import taskqueue
(...skipping 666 matching lines...) Expand 10 before | Expand all | Expand 10 after
677 } 677 }
678 ] 678 ]
679 try_job.put() 679 try_job.put()
680 680
681 analysis = WfAnalysis.Create(master_name, builder_name, build_number) 681 analysis = WfAnalysis.Create(master_name, builder_name, build_number)
682 analysis.status = analysis_status.COMPLETED 682 analysis.status = analysis_status.COMPLETED
683 analysis.failure_result_map = { 683 analysis.failure_result_map = {
684 'a': '/'.join([master_name, builder_name, '4']), 684 'a': '/'.join([master_name, builder_name, '4']),
685 'b on platform': { 685 'b on platform': {
686 'Unittest1.Subtest1': '/'.join([master_name, builder_name, '3']), 686 'Unittest1.Subtest1': '/'.join([master_name, builder_name, '3']),
687 'Unittest2.Subtest1': '/'.join([master_name, builder_name, '4']),
687 'Unittest3.Subtest1': '/'.join([master_name, builder_name, '4']), 688 'Unittest3.Subtest1': '/'.join([master_name, builder_name, '4']),
688 }, 689 },
689 } 690 }
690 analysis.result = { 691 analysis.result = {
691 'failures': [ 692 'failures': [
692 { 693 {
693 'step_name': 'a', 694 'step_name': 'a',
694 'first_failure': 4, 695 'first_failure': 4,
695 'last_pass': 3, 696 'last_pass': 3,
696 'suspected_cls': [ 697 'suspected_cls': [
(...skipping 362 matching lines...) Expand 10 before | Expand all | Expand 10 after
1059 1060
1060 1061
1061 def testGetStatusAndCulpritFromTryJobTryJobFailed(self): 1062 def testGetStatusAndCulpritFromTryJobTryJobFailed(self):
1062 try_job = WfTryJob.Create('m', 'b', 123) 1063 try_job = WfTryJob.Create('m', 'b', 123)
1063 try_job.status = analysis_status.ERROR 1064 try_job.status = analysis_status.ERROR
1064 try_job.put() 1065 try_job.put()
1065 status, culprit = findit_api.FindItApi()._GetStatusAndCulpritFromTryJob( 1066 status, culprit = findit_api.FindItApi()._GetStatusAndCulpritFromTryJob(
1066 try_job, None, None, None, None) 1067 try_job, None, None, None, None)
1067 self.assertEqual(status, findit_api._TryJobStatus.FINISHED) 1068 self.assertEqual(status, findit_api._TryJobStatus.FINISHED)
1068 self.assertIsNone(culprit) 1069 self.assertIsNone(culprit)
OLDNEW
« no previous file with comments | « appengine/findit/findit_api.py ('k') | appengine/findit/waterfall/suspected_cl_util.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698