Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
chore: create prdoc
  • Loading branch information
pandres95 committed Mar 7, 2024
commit be2d8c5a431a19d8fc1b1638b62b1d3f1f75501c
23 changes: 23 additions & 0 deletions prdoc/pr_3574.prdoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
title: Generate test functions for each benchmark with benchmarking v2

doc:
- audience: Runtime Dev
description: |
This PR fixes an issue where using `impl_benchmark_test_suite` macro
within modules that use the benchmarking v2 macros (`#[benchmarks]`
and `#[instance_benchmarks]`) always produced a single test called
`test_benchmarks` instead of a separate benchmark test for every
benchmark (noted with the `#[benchmark]` macro).

By using this macro from now on, new tests will be created named
`test_benchmark_{name}` where `name` is the name of the benchmark
function. Those tests will be nested inside the module intended for
benchmark functions.

Also, when using `impl_benchmark_test_suite` inside the module,
the import of such marco will not be necessary, so any explicit
import of it will be marked as unused, the same way it works for
v1 macros so far.

crates:
- name: frame-support-procedural