plugins/document_search/features/replace.feature in redcar-0.5 vs plugins/document_search/features/replace.feature in redcar-0.5.1dev
- old
+ new
@@ -14,15 +14,15 @@
Scenario: Replace next occurrence on the same line
When I replace the contents with "Foo\nBar Rab Rab\nBaz"
And I move the cursor to 4
And I run the command DocumentSearch::SearchAndReplaceCommand
And I type "Rab" into the "Search" field in the speedbar
- And I type "RABBIT" into the "Replace" field in the speedbar
+ And I type "RAB" into the "Replace" field in the speedbar
And I press "Replace" in the speedbar
- Then the contents should be "Foo\nBar RABBIT Rab\nBaz"
- And the selected text should be "RABBIT"
- And the selection range should be from 8 to 14
+ Then the contents should be "Foo\nBar RAB Rab\nBaz"
+ And the selected text should be "RAB"
+ And the selection range should be from 8 to 11
Scenario: Replace next occurrence on the same line twice
When I replace the contents with "Foo\nBar Rab Rab\nBaz"
And I move the cursor to 4
And I run the command DocumentSearch::SearchAndReplaceCommand
@@ -118,19 +118,6 @@
And I type "(\w+) chicken" into the "Search" field in the speedbar
And I type "\1 beef" into the "Replace" field in the speedbar
And I press "Replace" in the speedbar
Then the contents should be "Curry beef"
- Scenario: Replace should move past the current replacement if the query is a substring of the replacement
- When I replace the contents with "foo\nfoo\nfoo"
- And I move the cursor to 0
- And I run the command DocumentSearch::SearchAndReplaceCommand
- And I type "foo" into the "Search" field in the speedbar
- And I type "foobar" into the "Replace" field in the speedbar
- And I press "Replace" in the speedbar
- And I press "Replace" in the speedbar
- And I press "Replace" in the speedbar
- Then the contents should be "foobar\nfoobar\nfoobar"
- And the selection range should be from 14 to 20
-
-
\ No newline at end of file