-
Notifications
You must be signed in to change notification settings - Fork 19
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
add more contract api tests #794
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work!
/// The fee is volatile and depends on the number of pending requests. | ||
/// If used on a client side, it can give outdate results. | ||
pub fn experimantal_signature_deposit(&self) -> u128 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you! I think I've made that mistake in docs as well.
} | ||
|
||
#[tokio::test] | ||
async fn test_derived_public_key() -> anyhow::Result<()> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We will need to execute actual derivation logic in such a test. Not a blocker now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
agree. Probably good to be able to fix the pk in init_env() so we can test the value of the derived pk is correct.
|
||
let key: String = contract.view("public_key").await.unwrap().json().unwrap(); | ||
|
||
let execution = accounts[2] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should check that random acc can not vote for pk
} | ||
|
||
#[tokio::test] | ||
async fn test_derived_public_key() -> anyhow::Result<()> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
agree. Probably good to be able to fix the pk in init_env() so we can test the value of the derived pk is correct.
@ailisp merging, lets address all the comments if a follow up PR |
#764