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

tools: Fix block_search endpoint integration tests #999

Merged
merged 3 commits into from
Sep 30, 2021

Conversation

thanethomson
Copy link
Contributor

Closes #998

  • Referenced an issue explaining the need for the change
  • Updated all relevant documentation in docs
  • Updated all code comments where relevant
  • Wrote tests
  • Added entry in .changelog/

@xla xla changed the title Fix block_search endpoint integration tests tools: Fix block_search endpoint integration tests Sep 29, 2021
1,
Order::Ascending,
)
.block_search(Query::gt("block.height", 1), 1, 1, Order::Ascending)
Copy link
Contributor Author

@thanethomson thanethomson Sep 29, 2021

Choose a reason for hiding this comment

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

The original string representation was breaking CI. Changing it to a numerical value fixed it.

@@ -264,15 +260,21 @@ mod rpc {
}

async fn transaction_by_hash() {
let rpc_client = localhost_http_client();
Copy link
Contributor Author

Choose a reason for hiding this comment

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

These tests kept failing locally so I had to tweak them here too.

@thanethomson thanethomson marked this pull request as ready for review September 29, 2021 14:53
@codecov-commenter
Copy link

Codecov Report

Merging #999 (a9c86c1) into master (34c5d2a) will increase coverage by 0.0%.
The diff coverage is n/a.

Impacted file tree graph

@@          Coverage Diff           @@
##           master    #999   +/-   ##
======================================
  Coverage    72.5%   72.5%           
======================================
  Files         204     204           
  Lines       16655   16655           
======================================
+ Hits        12078   12081    +3     
+ Misses       4577    4574    -3     
Impacted Files Coverage Δ
light-client/src/types.rs 41.0% <0.0%> (ø)
tendermint/src/node.rs 66.1% <0.0%> (+0.2%) ⬆️
tendermint/src/block/commit_sig.rs 78.7% <0.0%> (+2.1%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 34c5d2a...a9c86c1. Read the comment docs.

@@ -125,7 +125,7 @@ jobs:
runs-on: ubuntu-latest
services:
tendermint:
image: informaldev/tendermint:0.34.0
image: informaldev/tendermint:0.34.13
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Important to note here that the block_search endpoint was only introduced in Tendermint v0.34.9.

@@ -1,6 +1,6 @@
[env]
CONTAINER_NAME = "kvstore-test"
DOCKER_IMAGE = "informaldev/tendermint:0.34.0"
DOCKER_IMAGE = "informaldev/tendermint:0.34.13"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Note that this needs to be maintained separately and coordinated with the .github/workflows/test.yml config because this cargo make makefile allows you to run the same tests locally.

Copy link
Contributor

@xla xla left a comment

Choose a reason for hiding this comment

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

💢 🍆 📹 🍷

@xla xla merged commit 4f1c553 into master Sep 30, 2021
@xla xla deleted the thane/998-block-search branch September 30, 2021 00:00
soareschen pushed a commit that referenced this pull request Oct 6, 2021
* Fix `cargo test` and add check to CI (#990)

* Relocate ABCI test to fix broken doctest

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

* Use tokio_test for mock client doctest

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

* Add CI test for default features

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

* Add `block_search` RPC endpoint (#991)

* Add block_search RPC endpoint and tests

* Add .changelog entry

* Fix comments

* tools: Fix `block_search` endpoint integration tests (#999)

Closes #998

* Bump integration test tendermint to v0.34.13
* Fix kvstore integration tests
* Bump tendermint version to v0.34.13 in CI

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

* ci: Build and check tools (#997)

So far only the kvstore tests ran as part of the Github workfows. This
would leave opportunity for changes to introduce breakage to the builds
of the tools. In this change the same build and clippy stages are
introduced for the tools workspace that currently run for the top-level
one.

Signed-off-by: xla <[email protected]>

* tools: Add `block_search` method to RPC probe (#1002)

* Add missing block_search endpoint
* Bump tendermint version to v0.34.13

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

Co-authored-by: Shoaib Ahmed <[email protected]>
Co-authored-by: xla <[email protected]>
thanethomson added a commit that referenced this pull request Oct 7, 2021
* Move out tendermint::config to tendermint_config crate

* Introduce own error type in tendermint-config

* Move tendermint::net to tendermint_config::net

* Fix tendermint-rpc error

* Update Cargo.toml for tendermint-config

* Remove #![allow(dead_code)]

* Apply suggestions from code review

Co-authored-by: Thane Thomson <[email protected]>

* Move tendermint_config::files::test to tendermint_config::test

* Remove config/tests/config.rs

* Minor fixes

* Resolve conflict in #986 (#1004)

* Fix `cargo test` and add check to CI (#990)

* Relocate ABCI test to fix broken doctest

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

* Use tokio_test for mock client doctest

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

* Add CI test for default features

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

* Add `block_search` RPC endpoint (#991)

* Add block_search RPC endpoint and tests

* Add .changelog entry

* Fix comments

* tools: Fix `block_search` endpoint integration tests (#999)

Closes #998

* Bump integration test tendermint to v0.34.13
* Fix kvstore integration tests
* Bump tendermint version to v0.34.13 in CI

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

* ci: Build and check tools (#997)

So far only the kvstore tests ran as part of the Github workfows. This
would leave opportunity for changes to introduce breakage to the builds
of the tools. In this change the same build and clippy stages are
introduced for the tools workspace that currently run for the top-level
one.

Signed-off-by: xla <[email protected]>

* tools: Add `block_search` method to RPC probe (#1002)

* Add missing block_search endpoint
* Bump tendermint version to v0.34.13

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

Co-authored-by: Shoaib Ahmed <[email protected]>
Co-authored-by: xla <[email protected]>

* Fix abci-test

* Add changelog entry

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

* Add more changelog entries for other breaking changes

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

* Add tendermint-config to release script

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

* Fix merge mistakes

Co-authored-by: Thane Thomson <[email protected]>
Co-authored-by: Shoaib Ahmed <[email protected]>
Co-authored-by: xla <[email protected]>
Co-authored-by: Thane Thomson <[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.

block_search endpoint isn't tested and doesn't work in CI integration tests
3 participants