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

integration testing scripts #64

Merged
merged 8 commits into from
Oct 4, 2022
Merged

integration testing scripts #64

merged 8 commits into from
Oct 4, 2022

Conversation

jeffreypicard
Copy link
Collaborator

some scripts for integration testing and a docker file for an action. Still need to figure out how to properly run a more realistic version in ci.

Copy link
Contributor

@moodyjon moodyjon left a comment

Choose a reason for hiding this comment

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

Also, this appears to fall back on /mnt/d/data/snapshot_1072108/lbry-rocksdb/ which I still don't know how to obtain, and I don't know how the GitHub runner gets a copy. I can live without it for now, but it would be great to be able to run locally.

--data '{"id": 1, "method": "blockchain.scripthash.get_mempool", "params":[{"scripthash": "bGqWuXRVm5bBqLvLPEQQpvsNxJ5ubc6bwN"}]}'
| jq .error | sed 's/"//g'
EOM
WANT="encoding/hex: invalid byte: U+0047 'G'"
Copy link
Contributor

Choose a reason for hiding this comment

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

Yeah.... the scripthash ones are tricky. I don't have an example of constructing one. Lbry-sdk does not send them.

I haven't figured it out yet, but see:
https://github.com/btcsuite/btcd/search?p=1&q=AddressScriptHash&type=Code

Copy link
Contributor

Choose a reason for hiding this comment

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

Just found this. Purports to convert addr to scripthash:
https://github.com/checksum0/go-electrum/blob/b862ac442cf9/electrum/address.go#L14

scripts/integration_tests.sh Outdated Show resolved Hide resolved
scripts/cicd_integration_test_runner.sh Outdated Show resolved Hide resolved
scripts/integration_tests.sh Outdated Show resolved Hide resolved
@lbry-bot lbry-bot assigned jeffreypicard and unassigned moodyjon Sep 21, 2022
@jeffreypicard
Copy link
Collaborator Author

This definitely requires a local and complete snapshot of the current db at this point. Which requires running your own hub to have in general. Another big piece of what else I'm working on, but not something that in general will be documented here. Getting this running as part of a ci runner we do need to figure out, there's a dependency on hundreds of gigabytes of data to do a "real" smoke test on, so it's not clear the best way to do this.

db/db.go Outdated Show resolved Hide resolved
db/db.go Outdated Show resolved Hide resolved
db/db.go Outdated Show resolved Hide resolved
db/db.go Outdated Show resolved Hide resolved
db/db.go Outdated Show resolved Hide resolved
db/db.go Outdated Show resolved Hide resolved
db/iteroptions.go Show resolved Hide resolved
db/db.go Outdated Show resolved Hide resolved
@lbry-bot lbry-bot assigned jeffreypicard and unassigned moodyjon Oct 3, 2022
some scripts for integration testing and a docker file for an action.
Still need to figure out how to properly run a more realistic version
in ci.
@jeffreypicard jeffreypicard merged commit 537b8c7 into master Oct 4, 2022
@jeffreypicard jeffreypicard deleted the integration_testing branch October 4, 2022 17:25
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