Subversion Repositories Kolibri OS

Rev

Rev 9339 | Rev 9342 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 9339 Rev 9340
Line 9... Line 9...
9
from shutil import which
9
from shutil import which
10
import timeit
10
import timeit
11
import urllib.request
11
import urllib.request
12
import subprocess
12
import subprocess
13
from threading import Thread
13
from threading import Thread
-
 
14
import filecmp
Line 14... Line 15...
14
 
15
 
15
sys.path.append('test')
16
sys.path.append('test')
Line 16... Line 17...
16
import common
17
import common
Line 226... Line 227...
226
def run_umka_test(root_dir, test_file_path):
227
def run_umka_test(root_dir, test_file_path):
227
    test = create_relocated(root_dir, test_file_path)
228
    test = create_relocated(root_dir, test_file_path)
228
    ref_log = create_relocated(root_dir, f"{test_file_path[:-2]}.ref.log")
229
    ref_log = create_relocated(root_dir, f"{test_file_path[:-2]}.ref.log")
229
    out_log = f"{test_file_path[:-2]}.out.log.o"
230
    out_log = f"{test_file_path[:-2]}.out.log.o"
230
    os.system(f"./umka_shell.exe < {test} > {out_log}")
231
    os.system(f"./umka_shell.exe < {test} > {out_log}")
231
    if os.system(f"cmp {ref_log} {out_log}") != 0:
232
    if not filecmp.cmp(ref_log, out_log):
232
        print(f"FAILURE: {test_file_path}\n", end = "")
233
        print(f"FAILURE: {test_file_path}\n", end = "")
233
    else:
234
    else:
234
        print(f"SUCCESS: {test_file_path}\n", end = "")
235
        print(f"SUCCESS: {test_file_path}\n", end = "")
Line 235... Line 236...
235
 
236