Skip to content

refactor: separate protocol test utils#21099

Merged
nventuro merged 1 commit intonextfrom
lw/protocol_test_utils
Mar 14, 2026
Merged

refactor: separate protocol test utils#21099
nventuro merged 1 commit intonextfrom
lw/protocol_test_utils

Conversation

@LeilaWang
Copy link
Contributor

Moving all protocol specific fixtures, builder, test utils from types to a separate protocol-test-utils crate, as types is expected to be used by aztec-nr users.

@LeilaWang LeilaWang force-pushed the lw/protocol_test_utils branch from a69cb7a to e32d754 Compare March 4, 2026 13:11
@LeilaWang LeilaWang requested a review from nventuro March 4, 2026 17:16
Copy link
Contributor

@nventuro nventuro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for working on this!

pub mod delayed_public_mutable;

pub mod tests;
pub mod test_utils;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not have these in the new crate?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are also used by some tests in types, and are more general, not protocol specific. So I thought to keep them in types.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we make that pub(crate) then so that they don't end up exposed via aztec-nr? I'd rather try to keep the API surface as small as possible to prevent accidental dependencies on these kinds of things.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They are also used outside of types by the tests of the circuits. Currently there are only 3 functions: pad_end, pad_end_with, and make_fixture. But if you still prefer not to expose these to aztec-nr users, I will copy them into protocol-test-utils.

@LeilaWang LeilaWang force-pushed the lw/protocol_test_utils branch from e32d754 to f4973c6 Compare March 13, 2026 13:04
Copy link
Contributor

@nventuro nventuro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lovely 🙌

@nventuro nventuro enabled auto-merge March 13, 2026 23:07
@nventuro nventuro added this pull request to the merge queue Mar 13, 2026
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Mar 13, 2026
@nventuro nventuro added this pull request to the merge queue Mar 13, 2026
Merged via the queue into next with commit 39dab49 Mar 14, 2026
33 checks passed
@nventuro nventuro deleted the lw/protocol_test_utils branch March 14, 2026 00:28
AztecBot pushed a commit that referenced this pull request Mar 14, 2026
Moving all protocol specific fixtures, builder, test utils from `types`
to a separate `protocol-test-utils` crate, as `types` is expected to be
used by aztec-nr users.
@AztecBot
Copy link
Collaborator

✅ Successfully backported to backport-to-v4-next-staging #21453.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants