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

Updated tests using testgen #615

Merged
merged 1 commit into from
Oct 7, 2020

Conversation

greg-szabo
Copy link
Member

  • Referenced an issue explaining the need for the change
  • Updated all relevant documentation in docs
  • Updated all code comments where relevant
  • Wrote tests
  • Updated CHANGELOG.md

@greg-szabo greg-szabo merged commit ff3cb43 into greg/aminoff3 Oct 7, 2020
@greg-szabo greg-szabo deleted the greg/aminoff3-model-based-test-fixes branch October 7, 2020 16:00
ebuchman pushed a commit that referenced this pull request Oct 8, 2020
* Removed amino traits, block, signature, vote

* tendermint: Fix header hashing

This commit fixes the header hashing mechanism to match that of the
current Go version. It also adds a test to ensure the happy path works.

Signed-off-by: Thane Thomson <[email protected]>

* light-client: Resolve #600

Demonstrates that the previous commit (fixing the header hash) fixes #600
when executed against a running Tendermint node.

Signed-off-by: Thane Thomson <[email protected]>

* tendermint: Use shorthand form of method call

Signed-off-by: Thane Thomson <[email protected]>

* tendermint: Add header hash check in integration test

Signed-off-by: Thane Thomson <[email protected]>

* tendermint: Add workaround for empty BlockId

Prost seems to encode an empty raw protobuf BlockId as an empty vector
of bytes, whereas the Go encoder encodes the same object to [18, 0].
This commit adds a workaround to demonstrate that this is the case when
testing against Tendermint v0.34 (otherwise header hashing would fail).

Signed-off-by: Thane Thomson <[email protected]>

* rpc: Update integration test fixture

It seems as though the previous commit data was generated by an older
version of Tendermint. The new commit fixtures here are generated by
Tendermint 0.34.0-99aea7b0 running in a Docker container on my local
machine.

Signed-off-by: Thane Thomson <[email protected]>

* Added Proposal domain type with signing - tests fail for now

* tendermint: Make last_block_id encoding workaround more explicit

Signed-off-by: Thane Thomson <[email protected]>

* tendermint: Fix empty last_block_id encoding issue

Signed-off-by: Thane Thomson <[email protected]>

* Proposal and Vote signable bytes functions

* PubKeyResponse made into PublicKey

* Header.Hash() fixes

* Merge conflict fixes

* Proposal test fixes

* Updated CHANGELOG

* Update CHANGELOG.md

* Update CHANGELOG.md

* regenerate static model-based files

* Update tendermint/Cargo.toml

* Remvoed amino bech32 encoding

* Updated priv_validator.json test with non-amino public key result

* Removed comments referencing amino.

* Review fixes #1

* Review fixes #2

* Review fixes #3

* Updated tests using testgen (#615)

* Update tendermint/src/public_key.rs

Co-authored-by: Tomas Tauber <[email protected]>

* fmt fix

* Fixes number four, additional derive traits

Co-authored-by: Thane Thomson <[email protected]>
Co-authored-by: Andrey Kuprianov <[email protected]>
Co-authored-by: Tomas Tauber <[email protected]>
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