Last modified: 2012-04-19 21:43:37 UTC
Reporting against Babaco Release. (Hosted on http://prototype.wikimedia.org) Steps to Reproduce :: 1) Start creating a new page 2) Add some text in the edit window 3) Click 'Search and replace' icon (e.g : Testing MediaWiki ) 4) Set search for (Test* ) and Replace with (TESTING) 5) Check flag 'Treat search string as a regular expression' 6) Click 'Replace' button <<Testing is replaced with TESTINGing >> Expected Outcome :: * in Search string is ignored * Also other regular expressions are ignored (^ , $ etc) Test Environment (Client) :: Browser (User-Agent): Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.1.2) Gecko/20090729 Firefox/3.5.2 Javascript: Enabled Cookies Enabled: Enabled Java Enabled: Enabled CPU class/type: OS/CPU Windows NT 6.0 Screen Width x Height: 1280 x 800 Screen Color Depth: 32
WORKSFORME? The regular expression /Test*/ will match "Tes" with any possible number of t's on the end. This could be "Tes" or potentially "Testtttttt". In any case, when using the string "Testing Mediawiki" and I replace /Test*/ with "TESTING" I get "TESTINGing Mediawiki" as I'd expect.
As mentioned in comment #1, test* only matching test and not testing is perfectly valid behavior. You seem to want test[^ ]* (test followed by any number of characters that aren't spaces).
Added keyword babaco to the bug