codex-storage / nim-codex

Decentralized Durability Engine
https://codex.storage
Apache License 2.0
68 stars 25 forks source link

Testing Plans #213

Open michaelsbradleyjr opened 2 years ago

michaelsbradleyjr commented 2 years ago

During the testground-focused team call today we discussed some key tests of correctness and resilience for nim-codex that should be documented and run manually by multiple members of the team.

There should also be automated equivalents of those same tests, making use of Testground.

Issue #98 needs to be resolved for these tests to work correctly.

  1. Upload a file to a node, download that file from the same node, check that the uploaded and downloaded file contents are identical (using a hash).

  2. Start two nodes, upload a file to one of the nodes, then download it from from the other one, check that file contents are identical (using a hash).

  3. Start four nodes, upload a file to one node, then download it from two others; when those downloads are complete, start downloading it from the remaining node and during that final download halt the node to which it was originally uploaded and one of the nodes from which it was downloaded previously. The file should still download correctly (can be checked using a hash).

Bulat-Ziganshin commented 2 years ago

A few ideas:

this way, we will don't need to store/download test files. Just generate it as required and make textfile with hash sums of files used in tests with lines size seed hashsum

michaelsbradleyjr commented 2 years ago

Good ideas. Using a hash is definitely the way to check that file contents are identical, I didn't mean to suggest contents need to be compared byte by byte. I've updated the original issue description.