Skip to content

Commit

Permalink
chore: update aws amplify
Browse files Browse the repository at this point in the history
  • Loading branch information
AtofStryker committed Feb 15, 2024
1 parent 31c5c9b commit dc4e1d8
Show file tree
Hide file tree
Showing 3 changed files with 1,157 additions and 2,369 deletions.
7 changes: 4 additions & 3 deletions cypress/support/auth-provider-commands/cognito.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { Amplify, Auth } from "aws-amplify";
import { Amplify } from "aws-amplify";
import { signIn } from "aws-amplify/auth"

Amplify.configure(Cypress.env("awsConfig"));

Expand All @@ -13,9 +14,9 @@ Cypress.Commands.add("loginByCognitoApi", (username, password) => {

log.snapshot("before");

const signIn = Auth.signIn({ username, password });
const signedIn = signIn({ username, password });

cy.wrap(signIn, { log: false }).then((cognitoResponse: any) => {
cy.wrap(signedIn, { log: false }).then((cognitoResponse: any) => {
const keyPrefixWithUsername = `${cognitoResponse.keyPrefix}.${cognitoResponse.username}`;
window.localStorage.setItem(
`${keyPrefixWithUsername}.idToken`,
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
},
"dependencies": {
"@auth0/auth0-react": "2.2.4",
"@aws-amplify/ui-react": "^5.0.4",
"@aws-amplify/ui-react": "^6.1.3",
"@babel/core": "7.23.9",
"@babel/plugin-syntax-flow": "^7.14.5",
"@babel/plugin-transform-react-jsx": "^7.14.9",
Expand All @@ -28,7 +28,7 @@
"@okta/okta-react": "^6.7.0",
"@types/detect-port": "^1.3.2",
"@xstate/react": "3.2.2",
"aws-amplify": "^5.3.3",
"aws-amplify": "^6.0.16",
"axios": "0.27.2",
"clsx": "1.2.1",
"date-fns": "2.30.0",
Expand Down
Loading

0 comments on commit dc4e1d8

Please sign in to comment.