run_part1_tests module¶
Autograder tests for Part 1.
Run this script (python3 run_part1_tests.py) from the same directory as
your client.py file. This will run all of the functionality tests for
Part 1 of the project.
-
class
run_part1_tests.ByteChangingServer¶ Bases:
servers.StorageServerSample malicious server that randomly changes bytes.
-
get(k)¶
-
-
run_part1_tests.FuzzTester(C, pks, crypto, server=<class 'run_part1_tests.ByteChangingServer'>)¶ Runs all functionality tests with a fuzz testing server.
-
class
run_part1_tests.StudentTester(theclass)¶ Bases:
object-
run_test(t, Server=<class 'servers.StorageServer'>, Crypto=<class 'crypto.Crypto'>, Pks=<class 'servers.PublicKeyServer'>)¶
-
-
run_part1_tests.run_part1_tests()¶ Runs all part 1 functionality tests.
-
run_part1_tests.t01_SimpleGetPut(C, pks, crypto, server)¶ Uploads a single file and checks the downloaded version is correct.
-
run_part1_tests.t02_SimpleGetPutNoState(C, pks, crypto, server)¶ Verifies that clients maintain no state about keys stored.
-
run_part1_tests.t03_SingleClientManyPuts(C, pks, crypto, server)¶ Uploads many files for the same user and checks they all uplad correctly.
-
run_part1_tests.t04_ValueDNE(C, pks, crypto, server)¶ Checks that values not stored at the server return None.
-
run_part1_tests.t05_NonCollidingNames(C, pks, crypto, server)¶ Uploads a file with the same name from two different users and checks for collisions.
-
run_part1_tests.t06_ManyGetPuts(C, pks, crypto, server)¶ Many clients upload many files and their contents are checked.
-
run_part1_tests.t07_SimpleGetPut(C, pks, crypto, server)¶ Tests that the server can handle long file names and keys