Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tests: test against bitbox02 simulators #69

Merged
merged 3 commits into from
Jul 5, 2024
Merged

tests: test against bitbox02 simulators #69

merged 3 commits into from
Jul 5, 2024

Conversation

benma
Copy link
Contributor

@benma benma commented Jun 3, 2024

More or less the same as

BitBoxSwiss/bitbox02-api-go#97

@benma benma force-pushed the simulator branch 7 times, most recently from 1aa9f8c to e7c46ae Compare June 4, 2024 11:46
@benma benma changed the title rust: add ability to connect to BitBox02 simulator tests: test against bitbox02 simulators Jul 3, 2024
@benma benma force-pushed the simulator branch 2 times, most recently from 9cde365 to 03fa692 Compare July 3, 2024 13:49
@benma benma requested a review from Beerosagos July 3, 2024 13:56
@benma benma marked this pull request as ready for review July 3, 2024 13:56
@benma benma force-pushed the simulator branch 4 times, most recently from 3ac59fd to b8e7de2 Compare July 4, 2024 22:34
benma added 3 commits July 5, 2024 00:53
The simulators are downloaded base on the simulators.json file if the
file does not exist (or the hash is wrong).

This allows us to exercise the library much more easily without
needing to mock everything, as the simulator behaves like the real
BitBox02 for the most part.

We could automatically download all releases by using the GitHub
releases
API (https://api.github.com/repos/BitBoxSwiss/bitbox02-firmware/releases),
but the downside is that there would be network requests each time you
run the unit tests. For now we simply keep the list manually.

The simulators are only released for linux-amd64 for now, so we skip
tests if we are not running in this environment.
@benma benma merged commit 2f43278 into master Jul 5, 2024
10 checks passed
@benma benma deleted the simulator branch July 5, 2024 09:36
@benma
Copy link
Contributor Author

benma commented Jul 5, 2024

Accidentally merged 🤦 I can address any issues in future PRs...

Copy link

@Beerosagos Beerosagos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants