Revision 27547e5fccda134560ad0441aa5bfa187387cec0 authored by Junio C Hamano on 16 April 2015, 17:48:58 UTC, committed by Junio C Hamano on 16 April 2015, 18:35:38 UTC
Signed-off-by: Junio C Hamano <gitster@pobox.com>
1 parent 599446d
Raw File
p7810-grep.sh
#!/bin/sh

test_description="git-grep performance in various modes"

. ./perf-lib.sh

test_perf_large_repo
test_checkout_worktree

test_perf 'grep worktree, cheap regex' '
	git grep some_nonexistent_string || :
'
test_perf 'grep worktree, expensive regex' '
	git grep "^.* *some_nonexistent_string$" || :
'
test_perf 'grep --cached, cheap regex' '
	git grep --cached some_nonexistent_string || :
'
test_perf 'grep --cached, expensive regex' '
	git grep --cached "^.* *some_nonexistent_string$" || :
'

test_done
back to top