0xMiden / 0xMiden/protocol

Refactor(testing): extract shared multisig auth test setup helper

オープン
#2,869 コメント 1 件 リアクション 1 件 担当者 0 名 GitHub で見る
主要言語
Rust
スター
132
フォーク
167
平均マージ
1日 23時間
マージ済み PR(30日)
110

説明

> [crates/miden-testing/tests/auth/multisig_smart.rs]
> ```
> (Vec, Vec, Vec, Vec);
>
> /// Sets up secret keys, auth schemes, public keys, and authenticators for a specific scheme.
> fn setup_keys_and_authenticators_with_scheme(
> ```
> Is it not possible to reuse the existing setup_keys_and_authenticators_with_scheme function which we use in the existing mutlisig?

Originally by: @partylikeits1983 in https://github.com/0xMiden/protocol/pull/2806

Extract the helper into a shared module reachable from every auth test:

```
crates/miden-testing/tests/auth/
mod.rs
common.rs # new — pub fn setup_keys_and_authenticators_with_scheme + MultisigTestSetup
multisig.rs
multisig_smart.rs
guarded_multisig.rs
hybrid_multisig.rs
```

Each test file then replaces its local copy with:

`use crate::auth::common::{MultisigTestSetup, setup_keys_and_authenticators_with_scheme};`

コントリビューションガイド

コントリビューションガイドを開く

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。