| Check to see that FilteredItemSelectionDialog uses proper regex to filter results. |
| |
| { |
| input : "["a","bc"]" |
| output : "["a","bc"]" |
| query : "" |
| title : "Empty query matches everything" |
| } |
| { |
| input : "["abc","acB"]" |
| output : "["acB"]" |
| query : "aB" |
| title : "Case sensitive matching" |
| } |
| { |
| input : "["abc","bac","a_B"]" |
| output : "["abc"]" |
| query : "ab" |
| title : "Case insensitive matching" |
| } |
| { |
| input : "["div .visible","div . visible "]" |
| output : "["div .visible"]" |
| query : "d.v " |
| title : "Spaces in the input" |
| } |
| { |
| input : "["abab","abaa","caab","baac","fooaab"]" |
| output : "["caab","fooaab"]" |
| query : "aab" |
| title : "Duplicate symbols in query" |
| } |
| { |
| input : "["abab","abaa","caab","baac","fooaab"]" |
| output : "["caab","fooaab"]" |
| query : "*aab" |
| title : "Star in query" |
| } |
| { |
| input : "["abab","abaa","caab","aqb","fooaab"]" |
| output : "["caab","aqb","fooaab"]" |
| query : "a?b" |
| title : "Question in query" |
| } |
| { |
| input : "["^[]{}()\\.$*+?|","0123456789abcdef"]" |
| output : "["^[]{}()\\.$*+?|"]" |
| query : "^[]{}()\.$*+?|" |
| title : "Dangerous input escaping" |
| } |
| { |
| input : "["fooBarBaz","FooBarBaz","Foo_Bar_Baz","foo_bar_baz","foobarbaz","foobarBaz","afooBarBaz","aFooBarBaz","a fooBarBaz","fooBorBaz","fooBorCaz"]" |
| output : "["fooBarBaz","afooBarBaz","a fooBarBaz"]" |
| query : "fBaB" |
| title : "Camel case matching" |
| } |
| { |
| input : "["foOBarBaz","FoOBarBaz","FoO_Bar_Baz","foO_bar_baz","foObarbaz","foObarBaz","afoOBarBaz","aFoOBarBaz","a foOBarBaz","foOBorBaz","foOBorCaz"]" |
| output : "["foO_bar_baz"]" |
| query : "fO_ba_b" |
| title : "Underscore matching" |
| } |
| { |
| input : "["foo_bar","FB","foobar","fBar"]" |
| output : "["FB","fBar"]" |
| query : "fb" |
| title : "Case insensitive matching" |
| } |
| { |
| input : "["foo_bar","FOO_BAR","Foo_Bar","fOo_bAr"]" |
| output : "["foo_bar","FOO_BAR","Foo_Bar","fOo_bAr"]" |
| query : "f_b" |
| title : "Case insensitive underscore matching" |
| } |
| |