upd: add some files

This commit is contained in:
2023-11-06 11:47:56 +08:00
parent 3e0ca43a03
commit 59aef02010
83 changed files with 32860 additions and 1 deletions

21
test/testcases/test.py Normal file
View File

@ -0,0 +1,21 @@
import filecmp
import os
if os.path.exists("temp"):
os.system("rm -rf ./temp")
os.makedirs("temp")
for i in range(14):
inst ="./code < testData/test"+str(i)+".in > temp/test"+str(i)+".out"
print(inst)
os.system(inst)
if not filecmp.cmp("testData/test"+str(i)+".out","temp/test"+str(i)+".out"):
f = open("testData/test" + str(i) + ".in", mode='r')
title = f.readline()[1:]
print("test", i, "wrong:", title)
os.system("rm -rf ./temp")
os.makedirs("temp")
for i in range(20):
inst = "./code < BigIntegerTest/BigIntegerTest" + str(i) + ".in > temp/test" + str(i) + ".out"
print(inst)
os.system(inst)
if not filecmp.cmp("BigIntegerTest/BigIntegerTest" + str(i) + ".out", "temp/test" + str(i) + ".out"):
print("big integer test", i, "wrong")