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

Removed useless test #58

Merged
merged 1 commit into from
Jan 16, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 0 additions & 52 deletions packages/cw-orch-polytone/src/deploy.rs
Original file line number Diff line number Diff line change
Expand Up @@ -91,55 +91,3 @@ impl<Chain: CwEnv> Polytone<Chain> {
Polytone { note, voice, proxy }
}
}

#[cfg(test)]
pub mod test {
use anyhow::Result as AnyResult;
use cw_orch::{
deploy::Deploy,
prelude::{
networks::{JUNO_1, UNI_6},
ContractInstance, DaemonBuilder,
},
tokio::runtime::Runtime,
};

use crate::Polytone;

/// This is a dummy mnemonic to have the daemon initialized properly
pub const TEST_MNEMONIC: &str = "clip hire initial neck maid actor venue client foam budget lock catalog sweet steak waste crater broccoli pipe steak sister coyote moment obvious choose";

#[test]
pub fn mainnet_test() -> AnyResult<()> {
let rt = Runtime::new()?;
let chain = DaemonBuilder::default()
.chain(JUNO_1)
.handle(rt.handle())
.mnemonic(TEST_MNEMONIC)
.build()?;

let polytone = Polytone::load_from(chain)?;
polytone.note.code_id()?;
polytone.voice.code_id()?;
polytone.proxy.code_id()?;

Ok(())
}

#[test]
pub fn testnet_test() -> AnyResult<()> {
let rt = Runtime::new()?;
let chain = DaemonBuilder::default()
.chain(UNI_6)
.handle(rt.handle())
.mnemonic(TEST_MNEMONIC)
.build()?;

let polytone = Polytone::load_from(chain)?;
polytone.note.code_id()?;
polytone.voice.code_id()?;
polytone.proxy.code_id()?;

Ok(())
}
}
Loading