File: test_concat.py

package info (click to toggle)
boinc 7.16.16%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 104,340 kB
  • sloc: cpp: 165,507; php: 115,918; pascal: 56,311; ansic: 49,284; xml: 17,140; java: 11,151; python: 6,617; javascript: 6,536; sh: 4,789; perl: 1,843; makefile: 1,818; objc: 1,724; sql: 1,003; lisp: 47; csh: 30
file content (47 lines) | stat: -rwxr-xr-x 1,640 bytes parent folder | download | duplicates (12)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#!/usr/bin/env python

## $Id$

# tests whether command-line arg passing works

from testbase import *

class WorkConcat(Work):
    def __init__(self, redundancy, **kwargs):
        Work.__init__(self, redundancy=redundancy)
        self.wu_template = "concat_wu"
        self.result_template = "concat_result"
        self.input_files = ['input']*2
        self.__dict__.update(kwargs)

class ProjectConcat(TestProject):
    def __init__(self, works=None, users=None, hosts=None):
        (num_wu, redundancy) = get_redundancy_args()
        TestProject.__init__(self,
                             appname = 'concat',
                             num_wu=num_wu, redundancy=redundancy,
                             expected_result = Result(),
                             works = works or [WorkConcat(redundancy=redundancy)],
                             users = users,
                             hosts = hosts)

    # def check(self):
    #     self.sched_run('validate_test')
    #     result = {}
    #     result['server_state'] = RESULT_SERVER_STATE_OVER
    #     self.check_results(result)
    #     self.check_files_match("upload/concat_wu_%d_0", "concat_correct_output", count=self.redundancy)
    #     self.sched_run('assimilator')
    #     self.sched_run('file_deleter')
    #     self.check_deleted("download/input")
    #     self.check_deleted("upload/concat_wu_%d_0", count=self.redundancy)

    # def run(self):
    #     self.install()
    #     self.sched_install('feeder')
    #     self.start_servers()

if __name__ == '__main__':
    test_msg("standard concat application");
    ProjectConcat()
    run_check_all()