| OLD | NEW |
| 1 # Copyright 2016 The Chromium Authors. All rights reserved. | 1 # Copyright 2016 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 from datetime import datetime | 5 from datetime import datetime |
| 6 import mock | 6 import mock |
| 7 | 7 |
| 8 from common import constants | 8 from common import constants |
| 9 from common.pipeline_wrapper import pipeline_handlers | 9 from common.pipeline_wrapper import pipeline_handlers |
| 10 from model import analysis_status | 10 from model import analysis_status |
| 11 from model import result_status |
| 11 from model.flake.flake_swarming_task import FlakeSwarmingTask | 12 from model.flake.flake_swarming_task import FlakeSwarmingTask |
| 12 from model.flake.master_flake_analysis import DataPoint | 13 from model.flake.master_flake_analysis import DataPoint |
| 13 from model.flake.master_flake_analysis import MasterFlakeAnalysis | 14 from model.flake.master_flake_analysis import MasterFlakeAnalysis |
| 14 from waterfall.flake import recursive_flake_pipeline | 15 from waterfall.flake import recursive_flake_pipeline |
| 15 from waterfall.flake.recursive_flake_pipeline import get_next_run | 16 from waterfall.flake.recursive_flake_pipeline import get_next_run |
| 16 from waterfall.flake.recursive_flake_pipeline import NextBuildNumberPipeline | 17 from waterfall.flake.recursive_flake_pipeline import NextBuildNumberPipeline |
| 17 from waterfall.flake.recursive_flake_pipeline import RecursiveFlakePipeline | 18 from waterfall.flake.recursive_flake_pipeline import RecursiveFlakePipeline |
| 18 from waterfall.flake.recursive_flake_pipeline import sequential_next_run | 19 from waterfall.flake.recursive_flake_pipeline import sequential_next_run |
| 19 from waterfall.test import wf_testcase | 20 from waterfall.test import wf_testcase |
| 20 | 21 |
| (...skipping 845 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 866 pipeline = NextBuildNumberPipeline() | 867 pipeline = NextBuildNumberPipeline() |
| 867 pipeline.run( | 868 pipeline.run( |
| 868 master_name, builder_name, | 869 master_name, builder_name, |
| 869 master_build_number, build_number, step_name, test_name, | 870 master_build_number, build_number, step_name, test_name, |
| 870 analysis.version_number, test_result_future, | 871 analysis.version_number, test_result_future, |
| 871 flakiness_algorithm_results_dict) | 872 flakiness_algorithm_results_dict) |
| 872 | 873 |
| 873 analysis = MasterFlakeAnalysis.GetVersion( | 874 analysis = MasterFlakeAnalysis.GetVersion( |
| 874 master_name, builder_name, master_build_number, step_name, test_name) | 875 master_name, builder_name, master_build_number, step_name, test_name) |
| 875 self.assertEqual(analysis_status.COMPLETED, analysis.status) | 876 self.assertEqual(analysis_status.COMPLETED, analysis.status) |
| 877 |
| 878 def testUpdateAnalysisUponCompletionFound(self): |
| 879 analysis = MasterFlakeAnalysis.Create('m', 'b', 123, 's', 't') |
| 880 analysis.suspected_flake_build_number = 100 |
| 881 recursive_flake_pipeline._UpdateAnalysisStatusUponCompletion( |
| 882 analysis, analysis_status.COMPLETED, None) |
| 883 self.assertEqual(analysis.result_status, result_status.FOUND_UNTRIAGED) |
| OLD | NEW |