diff --git a/source/api/commands/visit.md b/source/api/commands/visit.md index ffd7ff08a2..07cde77d3f 100644 --- a/source/api/commands/visit.md +++ b/source/api/commands/visit.md @@ -24,6 +24,7 @@ cy.visit(options) ```javascript cy.visit('http://localhost:3000') // Yields the window of the remote page +cy.visit('./pages/hello.html') ``` ## Arguments @@ -34,6 +35,9 @@ The URL to visit. Cypress will prefix the URL with the `baseUrl` configured in your {% url 'network options' configuration#Global %} if you've set one. +You may also specify the relative path of an html file. The path is relative to the root +directory of the Cypress installation. Note that the `file://` prefix is not needed. + **{% fa fa-angle-right %} options** ***(Object)*** Pass in an options object to control the behavior of `cy.visit()`.