1
votes

In Cypress, I have this testing code:

describe('In Viewport LARGE 1366', function() {
    it('Google', function() {
        //cy.visit('/');
        cy.log(Cypress.config().baseUrl);
    });
});

Cypress configuration is:

{
  "baseUrl": "https://www.google.com",
  "viewportWidth": 1300,
  "viewportHeight": 660
}

Cypress.json

Cypress version: 3.6

When I run the test, Cypress.config().baseUrl is localhost:1313 not google site as I mention in cypress.json

Running code

What is the problem ?

PS: with cy.visit('/'); I have the same problem - it points to http://localhost:1313

1

1 Answers

1
votes

The problem was at in cypress/support/index.js

Cypress.config('baseUrl', 'http://localhost:1313/');

and this overwritten cypress.json settings