equal
deleted
inserted
replaced
97 assert set(VARIANTS.keys()) == set(VARIANTS_KEYS) |
97 assert set(VARIANTS.keys()) == set(VARIANTS_KEYS) |
98 |
98 |
99 |
99 |
100 def parse_case(case): |
100 def parse_case(case): |
101 case_type, case_args = case.split('-', 1) |
101 case_type, case_args = case.split('-', 1) |
102 case = (case_type,) + tuple(int(x) for x in case_args.split('-')) |
102 if case_type == 'file': |
|
103 case_args = (case_args,) |
|
104 else: |
|
105 case_args = tuple(int(x) for x in case_args.split('-')) |
|
106 case = (case_type,) + case_args |
103 return case |
107 return case |
104 |
108 |
105 |
109 |
106 def format_case(case): |
110 def format_case(case): |
107 return '-'.join(str(s) for s in case) |
111 return '-'.join(str(s) for s in case) |
113 return 'not scratch(all(), %d, "%d")' % (case[1], case[2]) |
117 return 'not scratch(all(), %d, "%d")' % (case[1], case[2]) |
114 elif t == 'randomantichain': |
118 elif t == 'randomantichain': |
115 return '::randomantichain(all(), "%d")' % case[1] |
119 return '::randomantichain(all(), "%d")' % case[1] |
116 elif t == 'rev': |
120 elif t == 'rev': |
117 return '::%d' % case[1] |
121 return '::%d' % case[1] |
|
122 elif t == 'file': |
|
123 return '::nodefromfile("%s")' % case[1] |
118 else: |
124 else: |
119 assert False |
125 assert False |
120 |
126 |
121 |
127 |
122 def compare( |
128 def compare( |