Skip to content

Commit

Permalink
fix(e2e): fix url for snapshot tests
Browse files Browse the repository at this point in the history
We need to make the url match to bypass firewall settings.
  • Loading branch information
Liu233w authored and mergify[bot] committed Sep 29, 2023
1 parent 0441adf commit f39d19f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions e2e/__test__/pages/pages_snapshot.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ const superagent = require('superagent')
const cheerio = require('cheerio')
const request = require('superagent')

const basePath = 'http://localhost:3000'
const basePath = 'http://127.0.0.1:3000'

async function testPageByPath(path, authToken) {

Expand Down Expand Up @@ -142,11 +142,11 @@ for (let path of testPathsRequireLogin) {
}

test('/history', async () => {
await request.get('http://localhost:3000/mock-configurer/history-snapshot/history')
await request.get(`${basePath}/mock-configurer/history-snapshot/history`)
await testPageByPath('/history/', authToken)
})

test('/history/{historyId}', async () => {
await request.get('http://localhost:3000/mock-configurer/history-snapshot/summary')
await request.get(`${basePath}/mock-configurer/history-snapshot/summary`)
await testPageByPath('/history/1', authToken)
})

0 comments on commit f39d19f

Please sign in to comment.