,
+ }
+
+ async fn setup() -> SetupData {
telemetry_subscribers::init_for_testing();
let registry = Registry::new();
iota_metrics::init_metrics(®istry);
@@ -1578,7 +1563,7 @@ mod tests {
let (executor_handle, signing_tx, execution_tx) = executor.run_inner();
handles.extend(executor_handle);
- (
+ SetupData {
signing_tx,
execution_tx,
iota_client_mock,
@@ -1595,6 +1580,6 @@ mod tests {
iota_address,
iota_token_type_tags,
bridge_pause_tx,
- )
+ }
}
}
diff --git a/crates/iota-bridge/src/e2e_tests/test_utils.rs b/crates/iota-bridge/src/e2e_tests/test_utils.rs
index 35195b89d22..a836ae9888f 100644
--- a/crates/iota-bridge/src/e2e_tests/test_utils.rs
+++ b/crates/iota-bridge/src/e2e_tests/test_utils.rs
@@ -434,7 +434,6 @@ pub async fn get_eth_signer_client_e2e_test_only(
Ok((signer_0, private_key_0.to_string()))
}
-#[allow(dead_code)]
#[derive(Debug, Clone)]
pub struct DeployedSolContracts {
pub iota_bridge: EthAddress,
diff --git a/crates/iota-bridge/src/eth_syncer.rs b/crates/iota-bridge/src/eth_syncer.rs
index cdbd7bf59a6..2fb109dd0da 100644
--- a/crates/iota-bridge/src/eth_syncer.rs
+++ b/crates/iota-bridge/src/eth_syncer.rs
@@ -36,7 +36,6 @@ pub struct EthSyncer {
/// Map from contract address to their start block.
pub type EthTargetAddresses = HashMap;
-#[allow(clippy::new_without_default)]
impl EthSyncer
where
P: ethers::providers::JsonRpcClient + 'static,
diff --git a/crates/iota-bridge/src/iota_mock_client.rs b/crates/iota-bridge/src/iota_mock_client.rs
index 178e631de03..acf4fa4fd27 100644
--- a/crates/iota-bridge/src/iota_mock_client.rs
+++ b/crates/iota-bridge/src/iota_mock_client.rs
@@ -30,7 +30,7 @@ use crate::{
};
/// Mock client used in test environments.
-#[allow(clippy::type_complexity)]
+#[expect(clippy::type_complexity)]
#[derive(Clone, Debug)]
pub struct IotaMockClient {
// the top two fields do not change during tests so we don't need them to be Arc>
diff --git a/crates/iota-bridge/src/monitor.rs b/crates/iota-bridge/src/monitor.rs
index f2b0a551e51..3d483d216be 100644
--- a/crates/iota-bridge/src/monitor.rs
+++ b/crates/iota-bridge/src/monitor.rs
@@ -906,7 +906,7 @@ mod tests {
.unwrap();
}
- #[allow(clippy::type_complexity)]
+ #[expect(clippy::type_complexity)]
fn setup() -> (
iota_metrics::metered_channel::Sender,
iota_metrics::metered_channel::Receiver,
diff --git a/crates/iota-bridge/src/orchestrator.rs b/crates/iota-bridge/src/orchestrator.rs
index e0193d15230..8604d0fe28d 100644
--- a/crates/iota-bridge/src/orchestrator.rs
+++ b/crates/iota-bridge/src/orchestrator.rs
@@ -485,7 +485,7 @@ mod tests {
assert_eq!(digests.len(), 2);
}
- #[allow(clippy::type_complexity)]
+ #[expect(clippy::type_complexity)]
fn setup() -> (
iota_metrics::metered_channel::Sender<(Identifier, Vec)>,
iota_metrics::metered_channel::Receiver<(Identifier, Vec)>,
diff --git a/crates/iota-bridge/src/server/mock_handler.rs b/crates/iota-bridge/src/server/mock_handler.rs
index c986cf4e143..39505eba88f 100644
--- a/crates/iota-bridge/src/server/mock_handler.rs
+++ b/crates/iota-bridge/src/server/mock_handler.rs
@@ -26,7 +26,7 @@ use crate::{
types::SignedBridgeAction,
};
-#[allow(clippy::type_complexity)]
+#[expect(clippy::type_complexity)]
#[derive(Clone)]
pub struct BridgeRequestMockHandler {
signer: Arc>>,
diff --git a/crates/iota-cluster-test/src/lib.rs b/crates/iota-cluster-test/src/lib.rs
index b107bc08f3f..855ab846157 100644
--- a/crates/iota-cluster-test/src/lib.rs
+++ b/crates/iota-cluster-test/src/lib.rs
@@ -50,7 +50,6 @@ pub mod wallet_client;
pub use iota_genesis_builder::SnapshotUrl as MigrationSnapshotUrl;
-#[allow(unused)]
pub struct TestContext {
/// Cluster handle that allows access to various components in a cluster
cluster: Box,
diff --git a/crates/iota-common/src/sync/async_once_cell.rs b/crates/iota-common/src/sync/async_once_cell.rs
index b2759e4ba62..68cf5583271 100644
--- a/crates/iota-common/src/sync/async_once_cell.rs
+++ b/crates/iota-common/src/sync/async_once_cell.rs
@@ -42,7 +42,7 @@ impl AsyncOnceCell {
}
/// Sets the value and notifies waiters. Return error if called twice
- #[allow(clippy::result_unit_err)]
+ #[expect(clippy::result_unit_err)]
pub fn set(&self, value: T) -> Result<(), ()> {
let mut writer = self.writer.lock();
match writer.take() {
diff --git a/crates/iota-common/src/sync/notify_once.rs b/crates/iota-common/src/sync/notify_once.rs
index dfeb264ab4b..2c6b2b5eac8 100644
--- a/crates/iota-common/src/sync/notify_once.rs
+++ b/crates/iota-common/src/sync/notify_once.rs
@@ -35,7 +35,7 @@ impl NotifyOnce {
/// After this method all pending and future calls to .wait() will return
///
/// This method returns errors if called more then once
- #[allow(clippy::result_unit_err)]
+ #[expect(clippy::result_unit_err)]
pub fn notify(&self) -> Result<(), ()> {
let Some(notify) = self.notify.lock().take() else {
return Err(());
diff --git a/crates/iota-config/src/genesis.rs b/crates/iota-config/src/genesis.rs
index 3cb724e34b6..d7c850ca148 100644
--- a/crates/iota-config/src/genesis.rs
+++ b/crates/iota-config/src/genesis.rs
@@ -586,7 +586,7 @@ pub struct TokenDistributionScheduleBuilder {
}
impl TokenDistributionScheduleBuilder {
- #[allow(clippy::new_without_default)]
+ #[expect(clippy::new_without_default)]
pub fn new() -> Self {
Self {
pre_minted_supply: 0,
diff --git a/crates/iota-core/src/authority.rs b/crates/iota-core/src/authority.rs
index bd968065e99..d85c217974f 100644
--- a/crates/iota-core/src/authority.rs
+++ b/crates/iota-core/src/authority.rs
@@ -784,7 +784,7 @@ pub struct AuthorityState {
transaction_manager: Arc,
/// Shuts down the execution task. Used only in testing.
- #[allow(unused)]
+ #[cfg_attr(not(test), expect(unused))]
tx_execution_shutdown: Mutex