Skip to content

Commit

Permalink
feat(tests): eip-2537: Add inputs to mul precompiles
Browse files Browse the repository at this point in the history
  • Loading branch information
marioevz committed May 17, 2024
1 parent 9be500f commit 2e0832e
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
12 changes: 12 additions & 0 deletions tests/prague/eip2537_bls_12_381_precompiles/test_bls12_g1mul.py
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,18 @@ def test_valid(
Spec.P1_NOT_IN_SUBGROUP + Scalar(Spec.Q),
id="bls_g1mul_not_in_subgroup_times_q_2",
),
pytest.param(
Spec.G1 + Spec.G1,
id="bls_g1_add_input_invalid_length",
),
pytest.param(
Spec.G2 + Spec.G2,
id="bls_g2_add_input_invalid_length",
),
pytest.param(
Spec.G1,
id="bls_g1_truncated_input",
),
],
)
@pytest.mark.parametrize("expected_output", [Spec.INVALID], ids=[""])
Expand Down
12 changes: 12 additions & 0 deletions tests/prague/eip2537_bls_12_381_precompiles/test_bls12_g2mul.py
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,18 @@ def test_valid(
Spec.P2_NOT_IN_SUBGROUP + Scalar(Spec.Q),
id="bls_g2mul_not_in_subgroup_times_q",
),
pytest.param(
Spec.G1 + Spec.G1,
id="bls_g1_add_input_invalid_length",
),
pytest.param(
Spec.G2 + Spec.G2,
id="bls_g2_add_input_invalid_length",
),
pytest.param(
Spec.G2,
id="bls_g2_truncated_input",
),
],
)
@pytest.mark.parametrize("expected_output", [Spec.INVALID], ids=[""])
Expand Down

0 comments on commit 2e0832e

Please sign in to comment.