Skip to content

Commit

Permalink
fix(deps): update dependency @netlify/framework-info to ^9.5.0 (#5192)
Browse files Browse the repository at this point in the history
* fix(deps): update dependency @netlify/framework-info to ^9.5.0

* chore: wait for mock API to up and running before continuing

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Daniel Tschinder <231804+danez@users.noreply.github.com>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
  • Loading branch information
3 people committed Nov 4, 2022
1 parent 705a1b2 commit ba37074
Show file tree
Hide file tree
Showing 4 changed files with 39 additions and 33 deletions.
52 changes: 23 additions & 29 deletions npm-shrinkwrap.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Expand Up @@ -230,7 +230,7 @@
"@netlify/build": "^28.1.5",
"@netlify/config": "^19.1.1",
"@netlify/edge-bundler": "^3.1.1",
"@netlify/framework-info": "^9.3.0",
"@netlify/framework-info": "^9.5.0",
"@netlify/local-functions-proxy": "^1.1.1",
"@netlify/zip-it-and-ship-it": "^8.0.0",
"@octokit/rest": "^19.0.0",
Expand Down
2 changes: 1 addition & 1 deletion tests/integration/30.command.lm.test.cjs
Expand Up @@ -22,7 +22,7 @@ test.before(async (t) => {
name: 'site-name',
id_domain: 'localhost',
}
const { server } = startMockApi({
const { server } = await startMockApi({
routes: [
{ path: 'sites/site_id', response: siteInfo },
{ path: 'sites/site_id/service-instances', response: [] },
Expand Down
16 changes: 14 additions & 2 deletions tests/integration/utils/mock-api.cjs
Expand Up @@ -39,13 +39,25 @@ const startMockApi = ({ routes }) => {
res.json({ message: 'Not found' })
})

return { server: app.listen(), requests }
const returnPromise = new Promise((resolve, reject) => {
const server = app.listen()

server.on('listening', () => {
resolve({ server, requests })
})

server.on('error', (error) => {
reject(error)
})
})

return returnPromise
}

const withMockApi = async (routes, testHandler) => {
let mockApi
try {
mockApi = startMockApi({ routes })
mockApi = await startMockApi({ routes })
const apiUrl = `http://localhost:${mockApi.server.address().port}/api/v1`
return await testHandler({ apiUrl, requests: mockApi.requests })
} finally {
Expand Down

1 comment on commit ba37074

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📊 Benchmark results

Package size: 248 MB

Please sign in to comment.