Skip to content

Commit

Permalink
Add ability to specify mock folder location
Browse files Browse the repository at this point in the history
  • Loading branch information
mmercer884 authored and vscheuber committed Jan 21, 2025
1 parent ae79d49 commit ecc2ce7
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
4 changes: 0 additions & 4 deletions src/utils/ForgeRockUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,6 @@ export default (state: State): FRUtils => {
getIdmBaseUrl(): string {
return getIdmBaseUrl(state);
},
getRealmUsingExportFormat(realm: string): string {
return getRealmUsingExportFormat(realm);
},

// deprecated

getHostBaseUrl(url: string): string {
Expand Down
12 changes: 11 additions & 1 deletion src/utils/SetupPollyForFrodoLib.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ import {
Recording,
} from './PollyUtils';

const FRODO_TEST_NAME = process.env.FRODO_TEST_NAME

Check warning on line 17 in src/utils/SetupPollyForFrodoLib.ts

View workflow job for this annotation

GitHub Actions / Build

Delete `·`
? process.env.FRODO_TEST_NAME
: null

Check warning on line 19 in src/utils/SetupPollyForFrodoLib.ts

View workflow job for this annotation

GitHub Actions / Build

Insert `;`

const FRODO_MOCK_HOSTS = process.env.FRODO_MOCK_HOSTS
? process.env.FRODO_MOCK_HOSTS.split(',')
: [
Expand Down Expand Up @@ -102,7 +106,13 @@ function getFrodoArgsId({ start, state }: { start: number; state: State }) {
result.push(`${args.length}`);
const paramsId = params.join('_');
if (paramsId) result.push(paramsId);
const argsId = result.join('_');
const argsId = (process.env.FRODO_TEST_NAME) ? FRODO_TEST_NAME : result.join('_');

Check warning on line 109 in src/utils/SetupPollyForFrodoLib.ts

View workflow job for this annotation

GitHub Actions / Build

Replace `(process.env.FRODO_TEST_NAME)·?·FRODO_TEST_NAME` with `process.env.FRODO_TEST_NAME⏎····?·FRODO_TEST_NAME⏎···`
if(process.env.FRODO_TEST_NAME) {

Check warning on line 110 in src/utils/SetupPollyForFrodoLib.ts

View workflow job for this annotation

GitHub Actions / Build

Insert `·`
debugMessage({
message: `FRODO_TEST_NAME=${FRODO_TEST_NAME}`,
state

Check warning on line 113 in src/utils/SetupPollyForFrodoLib.ts

View workflow job for this annotation

GitHub Actions / Build

Insert `,`
})

Check warning on line 114 in src/utils/SetupPollyForFrodoLib.ts

View workflow job for this annotation

GitHub Actions / Build

Insert `;`
}
if (mode !== MODES.RECORD)
debugMessage({
message: `SetupPollyForFrodoLib.getFrodoArgsId: argsId=${argsId}`,
Expand Down

0 comments on commit ecc2ce7

Please sign in to comment.