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

chore: add integration tests to generate_message #1219

Merged
merged 16 commits into from
Aug 23, 2022

Conversation

prybalko
Copy link
Contributor

@prybalko prybalko commented Aug 16, 2022

Add integrations tests for generate_message CLI that doesn't do RPC calls

@@ -1065,14 +1065,16 @@
//!
//! `$ cargo run meta-at-block --url wss://westend-rpc.polkadot.io --block
//! 780812df50c4006d1865742269fe4ca339c097e61d6279cce91ebc58f5aebada`
#![deny(unused_crate_dependencies)]
#![deny(unused)]
Copy link
Contributor Author

Choose a reason for hiding this comment

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

There is a false-positive using unused_crate_dependencies rust-lang/rust#72686

@prybalko prybalko marked this pull request as ready for review August 18, 2022 07:43
Copy link
Contributor

@montekki montekki left a comment

Choose a reason for hiding this comment

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

lgtm ditto some nits


#[test]
fn it_derives() {
let files_dir = PathBuf::from("./tests/it_derives");
Copy link
Contributor

Choose a reason for hiding this comment

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

What I meant was rather something like tempdir::Tempdir::new("it_derives") which would be more convenient and deleted when it goes out of scope so it wouldn't be necessary to do the teardown in the end.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

👍

rust/generate_message/tests/make.rs Outdated Show resolved Hide resolved

#[test]
fn it_unwasm() {
let files_dir = PathBuf::from("./tests/it_unwasm");
Copy link
Contributor

Choose a reason for hiding this comment

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

probably should make all these relative variables as absolute with env!(CARGO_MANIFEST_DIR).push("./tests/it_unwasm") but I cannot really come up with a counterexample to the relative dir off the top of my head.

@prybalko prybalko merged commit 2007cea into master Aug 23, 2022
@prybalko prybalko deleted the add-generate_message-tests branch August 23, 2022 14:24
krodak added a commit that referenced this pull request Aug 24, 2022
* master:
  chore: add derived_keys_count to SeedNameCard (#1235)
  ci: pin gha versions (#1232)
  chore: fix build issues and Preview Content (#1234)
  chore: Revert "chore: fix build issues and Preview Content" (#1233)
  chore: fix build issues and Preview Content
  chore: scale identicons (#1230)
  chore: add integration tests to generate_message (#1219)
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