yarn install passport-atlassian-oauth2 and pass test case

Signed-off-by: Shousan Liao <samliao980822@gmail.com>
This commit is contained in:
Shousan Liao
2023-11-03 15:49:52 -04:00
parent 824b2d47d2
commit 260ee5106b
4 changed files with 3 additions and 4 deletions
@@ -28,7 +28,7 @@
"@backstage/plugin-auth-node": "workspace:^",
"express": "^4.18.2",
"passport": "^0.6.0",
"passport-atlassian2": "^5.0.0"
"passport-atlassian-oauth2": "^2.1.0"
},
"devDependencies": {
"@backstage/backend-defaults": "workspace:^",
@@ -14,7 +14,7 @@
* limitations under the License.
*/
import { Strategy as AtlassianStrategy } from 'passport-atlassian2';
import { Strategy as AtlassianStrategy } from 'passport-atlassian-oauth2';
import {
createOAuthAuthenticator,
PassportOAuthAuthenticatorHelper,
@@ -64,7 +64,6 @@ describe('authModuleAtlassianProvider', () => {
expect(startUrl.pathname).toBe('/oauth/authorize');
expect(Object.fromEntries(startUrl.searchParams)).toEqual({
response_type: 'code',
scope: 'read_user',
client_id: 'my-client-id',
redirect_uri: `http://localhost:${server.port()}/api/auth/atlassian/handler/frame`,
state: expect.any(String),
@@ -14,7 +14,7 @@
* limitations under the License.
*/
declare module 'passport-atlassian2' {
declare module 'passport-atlassian-oauth2' {
import { Request } from 'express';
import { StrategyCreated } from 'passport';