summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorwinniehell <git@winniehell.de>2016-09-07 13:40:14 +0200
committerwinniehell <git@winniehell.de>2016-09-07 15:11:42 +0200
commit0e3f7927d5b970ec18f8ce7a3a08ee0f9001f1d7 (patch)
treeca09ee0061d72ced3224bd0712ec9d3ac5e29eda
parentc61ebedaee2d1de76c961f54ca5f6b5805fcbe06 (diff)
downloadgitlab-ce-0e3f7927d5b970ec18f8ce7a3a08ee0f9001f1d7.tar.gz
Add failing test for #14360
-rw-r--r--spec/helpers/search_helper_spec.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/spec/helpers/search_helper_spec.rb b/spec/helpers/search_helper_spec.rb
index b0bb991539b..4b2ca3514f8 100644
--- a/spec/helpers/search_helper_spec.rb
+++ b/spec/helpers/search_helper_spec.rb
@@ -32,6 +32,10 @@ describe SearchHelper do
expect(search_autocomplete_opts("adm").size).to eq(1)
end
+ it "does not allow regular expression in search term" do
+ expect(search_autocomplete_opts("(webhooks|api)").size).to eq(0)
+ end
+
it "includes the user's groups" do
create(:group).add_owner(user)
expect(search_autocomplete_opts("gro").size).to eq(1)