Then I should be on the 404 page

Assert the page is (or is not) Joomla's answer to a missing page (404) or a refused one (403). The response status of the navigation must match, and the page must say so in one of the ways Joomla does: the error template of the site (body.error_site), the error template of the administrator (the error code in a badge), or, for a 403 that a component answers inside the normal template, the error message "You don't have permission to access this".

Examples

Then I should be on the 404 page
Then I should be on the page not found page
Then we should be on the 403 page
And I should not be on the 404 page
Then I should be on the access denied page

Pattern

Then(/^(I |we )*should( not)* be on the (404|page not found|403|access denied) page$/, …)

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