When I save the page

Save the page from the editor that is open (the source editor or the visual editor), with an edit summary and as a minor edit when asked. The step waits for the wiki's answer: the saved page, or an edit conflict (assert it with "Then I should see an edit conflict").

Examples

When I save the page
When I save the page with the summary "First version"
When I save the page as a minor edit with the summary "A typo"
And we save the page as a minor edit
When we save the page with the summary "A sentence in the visual editor"

Pattern

When(/^(I |we )*save the page( as a minor edit)?(?: with the summary "([^"]*)")?$/, …)

Part of @webship-js/mediawiki-steps (github.com/webship/mediawiki-steps), a step pack for Webship-js 2.0.x.