Summary
Description: Phoronix Test Suite open-source benchmarking development
Last Change: Tue 5/21/13 15:49
Recent Commits
>
--git a/pts-core/objects/client/display_modes/pts_concise_display_mode.php b/pts-core/objects/client/display_modes/pts_concise_display_mode.php
index 9cb7eb2..9db152d 100644
--- a/pts-core/objects/client/display_modes/pts_concise_display_mode.php
+++ b/pts-core/objects/client/display_modes/pts_concise_display_mode.php
@@ -275,7 +275,7 @@ class pts_concise_display_mode implements pts_display_mode_interface
$this->trial_run_count_current = 0;
$this->expected_trial_run_count = $test_result->test_profile->get_times_to_run();
- $remaining_length = $test_run_manager->get_estimated_run_time_remaining();
+ $remaining_length = $test_run_manager->get_estimated_run_time();
$estimated_length = $test_result->test_profile->get_estimated_run_time();
$display_table = array();
diff --git a/pts-core/objects/client/pts_test_run_manager.php b/pts-core/objects/client/pts_test_run_manager.php
index 925bf8a..1a44132 100644
--- a/pts-core/objects/client/pts_test_run_manager.php
+++ b/pts-core/objects/client/pts_test_run_manager.php
@@ -139,7 +139,7 @@ class pts_test_run_manager
}
}
- // No reason to increase the run count evidently
+ // No reason to increase the run count with none of the previous checks requesting otherwise
return false;
}
protected function add_test_result_object(&$test_result)
@@ -166,24 +166,17 @@ class pts_test_run_manager
return $identifiers;
}
- public function get_estimated_run_time()
+ public function get_estimated_run_time($index = -1)
{
- return $this->calculate_estimated_run_time(0);
- }
- public function get_estimated_run_time_remaining()
- {
- return $this->calculate_estimated_run_time($this->last_test_run_index);
- }
- private function calculate_estimated_run_time($index = 0)
- {
- $estimated_time = 0;
+ if($index == -1)
+ {
+ $index = $this->last_test_run_index;
+ }
- if(isset($this->tests_to_run[$index]))
+ $estimated_time = 0;
+ for($i = $index; $i < count($this->tests_to_run); $i++)
{
- for($i = $index; $i < count($this->tests_to_run); $i++)
- {
- $estimated_time += $this->tests_to_run[$i]->test_profile->get_estimated_run_time();
- }
+ $estimated_time += $this->tests_to_run[$i]->test_profile->get_estimated_run_time();
}
return $estimated_time;
<
Copyright © 2013 by Phoronix Media