Skip to content

Commit

Permalink
testsuite: refactor and replace dependencies test
Browse files Browse the repository at this point in the history
  • Loading branch information
Riolku committed Nov 5, 2022
1 parent bdf0d19 commit c91c9d8
Show file tree
Hide file tree
Showing 24 changed files with 78 additions and 35 deletions.
1 change: 0 additions & 1 deletion testsuite/batch_dependencies/1.txt

This file was deleted.

1 change: 0 additions & 1 deletion testsuite/batch_dependencies/2.txt

This file was deleted.

1 change: 0 additions & 1 deletion testsuite/batch_dependencies/3.txt

This file was deleted.

14 changes: 0 additions & 14 deletions testsuite/batch_dependencies/init.yml

This file was deleted.

1 change: 0 additions & 1 deletion testsuite/batch_dependencies/tests/python_ac_all/echo.py

This file was deleted.

5 changes: 0 additions & 5 deletions testsuite/batch_dependencies/tests/python_ac_all/test.yml

This file was deleted.

This file was deleted.

5 changes: 0 additions & 5 deletions testsuite/batch_dependencies/tests/python_pass_one/test.yml

This file was deleted.

This file was deleted.

5 changes: 0 additions & 5 deletions testsuite/batch_dependencies/tests/python_pass_two/test.yml

This file was deleted.

Binary file added testsuite/dependencies/data.zip
Binary file not shown.
20 changes: 20 additions & 0 deletions testsuite/dependencies/init.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
archive: data.zip
pretest_test_cases:
- &p1 {in: 1.txt, out: 4.txt}
- &p2 {in: 2.txt, out: 1.txt}
- &p3 {in: 3.txt, out: 10.txt, depends: [*p1]}
test_cases:
- &m1 {in: 5.txt, out: 16.txt, points: 1, depends: [*p1, *p3]}
- &m2
batched:
- {in: 4.txt, out: 2.txt}
- {in: 6.txt, out: 3.txt}
points: 1
depends: [*p2]
- &m3
batched:
- {in: 5.txt, out: 16.txt}
- {in: 10.txt, out: 5.txt}
points: 1
depends: [*m1, *m2]
- &m4 {in: 8.txt, out: 4.txt, points: 1, depends: [*m2]}
5 changes: 5 additions & 0 deletions testsuite/dependencies/tests/ac_all/sol.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
x = int(input())
if x % 2 == 1:
print(x * 3 + 1)
else:
print(x // 2)
5 changes: 5 additions & 0 deletions testsuite/dependencies/tests/ac_all/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: PY3
time: 2
memory: 65536
source: sol.py
cases: [AC, AC, AC, AC, AC, AC, AC, AC, AC]
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
x = int(input())
if x % 2 == 0:
print(x // 2)
elif x == 1:
print(4)
else:
print(10)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: PY3
time: 2
memory: 65536
source: hardcode_samples_solve_even.py
cases: [AC, AC, AC, WA, AC, AC, SC, SC, AC]
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
x = int(input())
if x == 1:
print(4)
elif x == 2:
print(1)
else:
print(10)
5 changes: 5 additions & 0 deletions testsuite/dependencies/tests/hardcode_samples/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: PY3
time: 2
memory: 65536
source: hardcode_samples.py
cases: [AC, AC, AC, WA, WA, SC, SC, SC, SC]
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
x = int(input())
if x % 2 == 1:
print(x * 3 + 1)
else:
print(1)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: PY3
time: 2
memory: 65536
source: hardcode_samples_solve_odd.py
cases: [AC, AC, AC, AC, WA, SC, SC, SC, SC]
2 changes: 2 additions & 0 deletions testsuite/dependencies/tests/solve_even/solve_even.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
x = int(input())
print(x // 2)
5 changes: 5 additions & 0 deletions testsuite/dependencies/tests/solve_even/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: PY3
time: 2
memory: 65536
source: solve_even.py
cases: [WA, SC, SC, SC, SC, SC, SC, SC, SC]
2 changes: 2 additions & 0 deletions testsuite/dependencies/tests/solve_odd/solve_odd.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
x = int(input())
print(x * 3 + 1)
5 changes: 5 additions & 0 deletions testsuite/dependencies/tests/solve_odd/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
language: PY3
time: 2
memory: 65536
source: solve_odd.py
cases: [AC, WA, SC, SC, SC, SC, SC, SC, SC]

0 comments on commit c91c9d8

Please sign in to comment.