Commit Graph

2822 Commits

Author SHA1 Message Date
rishflab
36ed3a0b8b Rename ImportOutput to reflect purpose 2020-10-09 11:40:00 +11:00
rishflab
213034dc1f Remove unused clone from states 2020-10-09 11:40:00 +11:00
rishflab
d01c05e5f5 Use intellij rust gitignore 2020-10-09 11:40:00 +11:00
rishflab
25edd90fb0 Remove empty lines between imports 2020-10-09 11:40:00 +11:00
rishflab
4e031ff9a2 Loop on blockchain call instead of delaying
Previously there was a delay making a get raw transaction call to
give some time for a transaction to be confirmed on the blockchain.
This has been replaced with a loop that waits until the call is
succesful.
2020-10-09 11:40:00 +11:00
rishflab
f6f4ec2bdb Fix dependencies 2020-10-09 11:40:00 +11:00
rishflab
148e49a959 Remove redundant lifetime parameter 2020-10-09 11:40:00 +11:00
rishflab
8754a9931b Execute Alice and Bob state machines concurrently
Previously we were testing the protocol by manually driving Alice and
Bob's state machines. This logic has now be moved to an async state
transition function that can take any possible state as input. The
state transition function is called in a loop until it returns the
desired state. This allows use to interrupt midway through the protocol
and perform refund and punish tests. This design was chosen over a
generator based implementation because the the generator based
implementation results in a impure state transition function that is
difficult to reason about and prone to bugs.

Test related code was extracted into the tests folder.

The 2b and 4b states were renamed to be consistent with the rest.

Macros were used to reduce code duplication when converting
child states to their parent states and vice versa.

Todos were added were neccessary.
2020-10-09 11:40:00 +11:00
Tobin C. Harding
3d3864807d
Merge pull request #7 from comit-network/debug-ci 2020-10-09 11:31:33 +11:00
Tobin C. Harding
e17575304b Add 60 sleep to workflow
There is some sort of timing issue when spinning up the monero containers on
github CI. I do not know exactly what is the cause but we have a configurable
'additional sleep time' already available for `testcontainers` that can resolve
this issue.

Use the environment variable MONERO_ADDITIONAL_SLEEP_PERIOD to tell
`testcontainers` to wait an additional 60 while bringing up the monero
container.
2020-10-09 11:16:15 +11:00
Tobin C. Harding
2064bfed5b Revert "Merge pull request #5 from comit-network/fix-ci"
This reverts commit 3b0b722d46, reversing
changes made to 93f1d960f5.
2020-10-09 09:57:28 +11:00
Tobin C. Harding
bfeb460073 Fix typo 2020-10-09 09:49:39 +11:00
Tobin C. Harding
30767ec755 Move alice/bob definition comment 2020-10-09 09:46:44 +11:00
Tobin C. Harding
1f89ea122e Fix embedded image 2020-10-09 09:45:48 +11:00
Tobin C. Harding
861dcc4a56 Update README
Update the readme inline with review suggestions by doing:

- Copy 'long story short' text from blog post
- Correct the erroneous description of watching blockchains
- Fix gramar
2020-10-09 09:34:24 +11:00
Philipp Hoenisch
3b0b722d46
Merge pull request #5 from comit-network/fix-ci
Run CI tests on one thread
2020-10-08 15:51:22 +11:00
rishflab
e8ffed6979 Run CI tests on one thread
This is quick and dirty fix to resolve xmr-btc-swap and
monero-harness tests failing in CI when run concurrently.
2020-10-08 15:37:39 +11:00
Tobin C. Harding
65b0e54a5f Add a README.md file
Add a readme that describes the project. Specifically

- module structure
- what we prove and do not prove
- how we test
2020-10-08 09:17:39 +11:00
Lucas Soriano
93f1d960f5
Merge pull request #1 from comit-network/actual-work
Swap Monero for Bitcoin
2020-09-28 17:56:48 +10:00
Lucas Soriano del Pino
b9c202efc9 Remove redundant license 2020-09-28 17:18:02 +10:00
Lucas Soriano del Pino
1f99cf001c Swap Monero for Bitcoin
Co-authored-by: rishflab <rishflab@hotmail.com>
Co-authored-by: Philipp Hoenisch <philipp@hoenisch.at>
Co-authored-by: Tobin C. Harding <tobin@coblox.tech>
2020-09-28 17:15:57 +10:00
rishflab
818e522bd4
Initial commit 2020-09-28 15:55:08 +10:00