https://cypress.io logo
you could use a foreach to reduce a bit of duplica...
# e2e-testing
a
you could use a foreach to reduce a bit of duplication.
errorHosts.forEach(hostname => cy.intercept({hostname}, {statusCode: 503});
where errorHosts is an array ['host1.com', 'host2.com, ...]