mirror of
https://github.com/aljazceru/pubky-core.git
synced 2026-01-03 14:24:26 +01:00
fix: cargo clippy
This commit is contained in:
@@ -206,7 +206,7 @@ mod tests {
|
||||
let mut invalid = authn_signature.as_bytes().to_vec();
|
||||
invalid[64..].copy_from_slice(&[0; 32]);
|
||||
|
||||
assert!(!verifier.verify(&invalid, &signer).is_ok())
|
||||
assert!(verifier.verify(&invalid, &signer).is_err())
|
||||
}
|
||||
|
||||
{
|
||||
@@ -214,7 +214,7 @@ mod tests {
|
||||
let mut invalid = authn_signature.as_bytes().to_vec();
|
||||
invalid[0..32].copy_from_slice(&[0; 32]);
|
||||
|
||||
assert!(!verifier.verify(&invalid, &signer).is_ok())
|
||||
assert!(verifier.verify(&invalid, &signer).is_err())
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -69,9 +69,10 @@ mod tests {
|
||||
|
||||
#[test]
|
||||
fn serialize() {
|
||||
let mut session = Session::default();
|
||||
|
||||
session.user_agent = "foo".to_string();
|
||||
let session = Session {
|
||||
user_agent: "foo".to_string(),
|
||||
..Default::default()
|
||||
};
|
||||
|
||||
let serialized = session.serialize();
|
||||
|
||||
|
||||
@@ -112,7 +112,7 @@ mod tests {
|
||||
|
||||
match session {
|
||||
Err(Error::NotSignedIn) => {}
|
||||
_ => assert!(false, "expected NotSignedInt error"),
|
||||
_ => panic!("expected NotSignedInt error"),
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -18,9 +18,7 @@ if_not_wasm! {
|
||||
mod client;
|
||||
mod client_async;
|
||||
|
||||
use pkarr::{PkarrClient};
|
||||
use ureq::{Agent, Response};
|
||||
use url::Url;
|
||||
use client::PubkyClient;
|
||||
}
|
||||
|
||||
if_wasm! {
|
||||
|
||||
Reference in New Issue
Block a user