-
Notifications
You must be signed in to change notification settings - Fork 382
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Disable Universe Domain Check (#1878)
* fix: Disable Universe Domain Check * chore: compodoc nonsense
- Loading branch information
Showing
3 changed files
with
2 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1149,9 +1149,8 @@ describe('googleauth', () => { | |
|
||
it('getCredentials should get metadata from the server when running on GCE', async () => { | ||
const clientEmail = '[email protected]'; | ||
const universeDomain = 'my-amazing-universe.com'; | ||
const scopes = [ | ||
nockIsGCE({universeDomain}), | ||
nockIsGCE(), | ||
createGetProjectIdNock(), | ||
nock(host).get(svcAccountPath).reply(200, clientEmail, HEADERS), | ||
]; | ||
|
@@ -1160,7 +1159,6 @@ describe('googleauth', () => { | |
const body = await auth.getCredentials(); | ||
assert.ok(body); | ||
assert.strictEqual(body.client_email, clientEmail); | ||
assert.strictEqual(body.universe_domain, universeDomain); | ||
assert.strictEqual(body.private_key, undefined); | ||
scopes.forEach(s => s.done()); | ||
}); | ||
|
@@ -1644,14 +1642,6 @@ describe('googleauth', () => { | |
assert.notEqual(universe_domain, DEFAULT_UNIVERSE); | ||
assert.equal(await auth.getUniverseDomain(), universe_domain); | ||
}); | ||
|
||
it('should use the metadata service if on GCP', async () => { | ||
const universeDomain = 'my.universe.com'; | ||
const scope = nockIsGCE({universeDomain}); | ||
|
||
assert.equal(await auth.getUniverseDomain(), universeDomain); | ||
await scope.done(); | ||
}); | ||
}); | ||
|
||
function mockApplicationDefaultCredentials(path: string) { | ||
|