Skip to content

Commit

Permalink
Verify the proxy has only the internal/external networks attached
Browse files Browse the repository at this point in the history
  • Loading branch information
Jurre Stender committed Oct 25, 2021
1 parent 97c0909 commit e8dd707
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions __tests__/proxy-integration.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,12 @@ describe('ProxyBuilder', () => {
expect(networkInfo.Name).toBe('dependabot-job-1-internal-network')
expect(networkInfo.Internal).toBe(true)

const networkNames = Object.keys(containerInfo.NetworkSettings.Networks)
expect(networkNames).toEqual([
'dependabot-job-1-external-network',
'dependabot-job-1-internal-network'
])

// run a bash command that executes docker and returns contents of /config.json
const id = proxy.container.id
const proc = spawnSync('docker', ['exec', id, 'cat', '/config.json'])
Expand Down

0 comments on commit e8dd707

Please sign in to comment.