diff --git a/checkin_notes b/checkin_notes index 62c4a53501..6366528f55 100755 --- a/checkin_notes +++ b/checkin_notes @@ -5014,7 +5014,7 @@ Karl 2003/06/23 util.C util.h -Karl 2003/06/23 +Karl 2003/06/23 - removed stderr messages on detach_project() after user adds a URL that doesn't work @@ -5032,3 +5032,13 @@ John Brian 2003/06/24 resource.rc resource.h +Karl 2003/06/23 + - Got test_1sec working + + test/ + boinc.py + test.inc + test_backend.py + test_uc.py + sched/ + start_servers.C diff --git a/test/boinc.py b/test/boinc.py index 4a9e8bd7b1..37b7bbd0e5 100644 --- a/test/boinc.py +++ b/test/boinc.py @@ -287,6 +287,7 @@ class Project: add_to_list=True): if add_to_list: all_projects.append(self) + self.configlines = [] self.short_name = short_name or 'test_'+appname self.long_name = long_name or 'Project ' + self.short_name.replace('_',' ').capitalize() self.db_passwd = '' @@ -638,7 +639,6 @@ class Project: except OSError: pass - configlines = [] def append_config(self, line): self.configlines += line.split('\n') self.write_config() @@ -843,6 +843,8 @@ def run_check_all(): '''Run all projects, run all hosts, check all projects, stop all projects.''' all_projects.run() all_projects.open_dbs() # for progress meter + if os.environ.get('TEST_STOP_BEFORE_HOST_RUN'): + raise SystemExit, 'Stopped due to $TEST_STOP_BEFORE_HOST_RUN' rm = ResultMeter(all_projects.progress) all_hosts.run() rm.stop() @@ -868,6 +870,7 @@ def stop_proxy(): os.kill(2, proxy_pid) def test_msg(msg): + print print "-- Testing", msg, '-'*(66-len(msg)) def test_done(): diff --git a/test/test.inc b/test/test.inc index 3841be5fc6..aa6e04a1af 100644 --- a/test/test.inc +++ b/test/test.inc @@ -178,6 +178,7 @@ function account_file_name($url) { $x = $url; } $encoded_name = strtr($x, "/", "_"); + $encoded_name = substr($encoded_name, 0,strlen($encoded_name)-1); return "account_".$encoded_name.".xml"; } @@ -477,7 +478,7 @@ class Project { $this->copy('html_user/*.html' , 'html_user/'); $this->copy('html_ops/*.php' , 'html_ops/'); $this->copy('html_ops/*.inc' , 'html_ops/'); - $this->copy('html_ops/*.html' , 'html_ops/'); + // $this->copy('html_ops/*.html' , 'html_ops/'); $this->copy('tools/country_select' , 'html_user/'); if ($this->project_php_file) { $this->copy('html_user/$this->project_php_file', 'html_user/project.inc'); diff --git a/test/test_backend.py b/test/test_backend.py index 3e18fe6f83..fbf2184112 100755 --- a/test/test_backend.py +++ b/test/test_backend.py @@ -53,6 +53,7 @@ class ProjectBackend(ProjectUC): self.check_results(self.num, ResultUC()) if __name__ == '__main__': - test_msg("entire backend"); - ProjectBackend(sys.argv[1:] and get_int(sys.argv[1]) or 100) + num = sys.argv[1:] and get_int(sys.argv[1]) or 100 + test_msg("entire backend (with %d results)" % num); + ProjectBackend(num) run_check_all() diff --git a/test/test_uc.py b/test/test_uc.py index 5dbb6c9fd4..ac64c5fd9c 100755 --- a/test/test_uc.py +++ b/test/test_uc.py @@ -28,10 +28,13 @@ class WorkUC(Work): self.redundancy = redundancy self.delay_bound = 5*redundancy self.input_files = ['input'] - # Say that 1 WU takes 1 day on a ref comp - self.rsc_fpops = 86400*1e9/2 - self.rsc_iops = 86400*1e9/2 - self.rsc_disk = 10e8 + # # Say that 1 WU takes 1 day on a ref comp + # - note: for test_1sec these values are too high so if you want to + # add these back, make them smaller of make test_1sec + # request more work + # self.rsc_fpops = 86400*1e9/2 + # self.rsc_iops = 86400*1e9/2 + # self.rsc_disk = 10e8 class ResultUC: def __init__(self):