diff options
author | Ævar Arnfjörð Bjarmason <avarab@gmail.com> | 2017-04-21 19:44:28 +0000 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-04-23 21:33:15 -0700 |
commit | db7ed0f20c2929f3054c96497dd1cf482a198c7b (patch) | |
tree | 74d0209254173fc1aedbc5fb5081769906451ec4 /t/perf/p0000-perf-lib-sanity.sh | |
parent | Git 2.13-rc0 (diff) | |
download | tgif-db7ed0f20c2929f3054c96497dd1cf482a198c7b.tar.xz |
t/perf: correctly align non-ASCII descriptions in output
Change the test descriptions from being treated as binary blobs by
perl to being treated as UTF-8. This ensures that e.g. a test
description like "æ" is counted as 1 character, not 2.
I have WIP performance tests for non-ASCII grep patterns on another
topic that are affected by this.
Now instead of:
$ ./run p0000-perf-lib-sanity.sh
[...]
0000.4: export a weird var 0.00(0.00+0.00)
0000.5: éḿíẗ ńöń-ÁŚĆÍÍ ćḧáŕáćẗéŕś 0.00(0.00+0.00)
0000.7: important variables available in subshells 0.00(0.00+0.00)
[...]
We emit:
[...]
0000.4: export a weird var 0.00(0.00+0.00)
0000.5: éḿíẗ ńöń-ÁŚĆÍÍ ćḧáŕáćẗéŕś 0.00(0.00+0.00)
0000.7: important variables available in subshells 0.00(0.00+0.00)
[...]
Fixes code originally added in 342e9ef2d9 ("Introduce a performance
testing framework", 2012-02-17).
Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/perf/p0000-perf-lib-sanity.sh')
-rwxr-xr-x | t/perf/p0000-perf-lib-sanity.sh | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/t/perf/p0000-perf-lib-sanity.sh b/t/perf/p0000-perf-lib-sanity.sh index cf8e1efce7..002c21e52a 100755 --- a/t/perf/p0000-perf-lib-sanity.sh +++ b/t/perf/p0000-perf-lib-sanity.sh @@ -33,6 +33,8 @@ test_perf 'export a weird var' ' test_export bar ' +test_perf 'éḿíẗ ńöń-ÁŚĆÍÍ ćḧáŕáćẗéŕś' 'true' + test_expect_success 'test_export works with weird vars' ' echo "$bar" && test "$bar" = "weird # variable" |