Files
cypress/system-tests/test/base_url_spec.js
Jessica Sachs a045e4f59a chore: move server e2e tests to system-tests (#16354)
Co-authored-by: Brian Mann <brian.mann86@gmail.com>
Co-authored-by: Zach Bloomquist <git@chary.us>
Co-authored-by: Zach Bloomquist <github@chary.us>
2021-10-18 19:53:14 +00:00

40 lines
745 B
JavaScript

const systemTests = require('../lib/system-tests').default
const onServer = (app) => {
return app.get('/app/html', (req, res) => {
return res.send('<html>Herman Melville</html>')
})
}
describe('e2e baseUrl', () => {
context('https', () => {
systemTests.setup({
settings: {
baseUrl: 'https://httpbin.org',
},
})
systemTests.it('passes', {
spec: 'base_url_spec.js',
snapshot: true,
})
})
context('http', () => {
systemTests.setup({
servers: {
port: 9999,
onServer,
},
settings: {
baseUrl: 'http://localhost:9999/app',
},
})
systemTests.it('passes', {
spec: 'base_url_spec.js',
snapshot: true,
})
})
})