Skip to content

Commit

Permalink
Merge master into feature/q-dev-ux
Browse files Browse the repository at this point in the history
  • Loading branch information
aws-toolkit-automation authored Oct 16, 2024
2 parents 5bf9de2 + 8a5b8d9 commit 4245dd6
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,31 +18,20 @@ import {
import { UserCredentialsUtils } from '../../../shared/credentials/userCredentialsUtils'
import { EnvironmentVariables } from '../../../shared/environmentVariables'
import { makeTemporaryToolkitFolder } from '../../../shared/filesystemUtilities'
import { getConfigFilename, getCredentialsFilename } from '../../../auth/credentials/sharedCredentialsFile'
import { fs } from '../../../shared'

describe('UserCredentialsUtils', function () {
let tempFolder: string
let defaultConfigFileName: string
let defaultCredentialsFilename: string

before(async function () {
defaultConfigFileName = getConfigFilename()
defaultCredentialsFilename = getCredentialsFilename()
beforeEach(async function () {
// Make a temp folder for all these tests
// Stick some temp credentials files in there to load from
tempFolder = await makeTemporaryToolkitFolder()
})

afterEach(async function () {
await fs.delete(defaultConfigFileName, { recursive: true })
await fs.delete(defaultCredentialsFilename, { recursive: true })

sinon.restore()
})

after(async function () {
await fs.delete(tempFolder, { recursive: true })
sinon.restore()
})

describe('findExistingCredentialsFilenames', function () {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"type": "Bug Fix",
"description": "Fix userCredentialsUtils.test.ts so it won't remove the actual aws config"
}

0 comments on commit 4245dd6

Please sign in to comment.