internal/testtext: add Bench function

Allows backwards compatible sub-benchmarks.
Benchmarks will only run in 1.7.

Change-Id: I81c4a8277a1d6790b48c67c326f6ae6242b2b758
Reviewed-on: https://go-review.googlesource.com/29177
Run-TryBot: Marcel van Lohuizen <mpvl@golang.org>
Reviewed-by: Nigel Tao <nigeltao@golang.org>
2 files changed