diff options
| author | hopehook <hopehook.com@gmail.com> | 2022-07-30 12:47:51 +0800 |
|---|---|---|
| committer | Gopher Robot <gobot@golang.org> | 2022-08-25 17:58:32 +0000 |
| commit | 396b153ec454cd427f97be4d994a903e2c4b244f (patch) | |
| tree | 2c95f827e57b82b7620aed67c2f69238d1a488cf /api | |
| parent | 83b5fe63514411f425061967fd8c1d506f2ac40f (diff) | |
| download | go-396b153ec454cd427f97be4d994a903e2c4b244f.tar.xz | |
testing: add Elapsed method to testing.B
Elapsed returns the measured elapsed time of the benchmark,
but does not change the running state of the timer.
Fixes #43620.
Change-Id: Idd9f64c4632518eec759d2ffccbf0050d84fcc03
Reviewed-on: https://go-review.googlesource.com/c/go/+/420254
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Auto-Submit: Bryan Mills <bcmills@google.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Run-TryBot: hopehook <hopehook@qq.com>
Reviewed-by: Bryan Mills <bcmills@google.com>
Diffstat (limited to 'api')
| -rw-r--r-- | api/next/43620.txt | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/api/next/43620.txt b/api/next/43620.txt new file mode 100644 index 0000000000..9d272fd0c7 --- /dev/null +++ b/api/next/43620.txt @@ -0,0 +1 @@ +pkg testing, method (*B) Elapsed() time.Duration #43620
\ No newline at end of file |
