Skip to content

Commit

Permalink
add test for Gateway Constructor
Browse files Browse the repository at this point in the history
  • Loading branch information
insipx committed Jan 25, 2024
1 parent 85ac24e commit 85f5e92
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 16 deletions.
26 changes: 14 additions & 12 deletions registry/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -38,18 +38,20 @@ where
"Revoking attribute {:#?}",
String::from_utf8_lossy(&attribute)
);
self.registry
.revoke_attribute_signed(
address,
signature.v.try_into()?,
signature.r.into(),
signature.s.into(),
attribute,
value.into(),
)
.send()
.await?
.await?;
let res = self.registry.revoke_attribute_signed(
address,
signature.v.try_into()?,
signature.r.into(),
signature.s.into(),
attribute,
value.into(),
);

let res = res.send().await;
if let Err(ref e) = res {
println!("{}", e);

Check warning on line 52 in registry/src/lib.rs

View check run for this annotation

Codecov / codecov/patch

registry/src/lib.rs#L52

Added line #L52 was not covered by tests
}
res?.await?;

Ok(())
}
Expand Down
5 changes: 1 addition & 4 deletions xps-gateway/src/rpc/methods.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,7 @@ use super::api::*;
use jsonrpsee::types::error::ErrorCode;

use async_trait::async_trait;
use ethers::{
core::types::Signature,
providers::{Middleware, Provider, Ws},
};
use ethers::{core::types::Signature, providers::Middleware};
use jsonrpsee::types::ErrorObjectOwned;
use lib_didethresolver::types::XmtpAttribute;
use thiserror::Error;
Expand Down

0 comments on commit 85f5e92

Please sign in to comment.