Skip to content

Commit

Permalink
Add star to support query param (#1266)
Browse files Browse the repository at this point in the history
Signed-off-by: Derek Ho <dxho@amazon.com>
  • Loading branch information
derek-ho authored May 3, 2024
1 parent 1f691b2 commit a2034d4
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions cypress/utils/plugins/security/commands.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import {
Cypress.Commands.add(
'mockAuthAction',
function (fixtureFileName, funcMockedOn) {
cy.intercept(SEC_API_CONFIG_PATH, {
cy.intercept(`${SEC_API_CONFIG_PATH}*`, {
fixture: fixtureFileName,
}).as('getAuthDetails');

Expand All @@ -35,7 +35,7 @@ Cypress.Commands.add(
Cypress.Commands.add(
'mockRolesAction',
function (fixtureFileName, funcMockedOn) {
cy.intercept(SEC_API_ROLES_PATH, {
cy.intercept(`${SEC_API_ROLES_PATH}*`, {
fixture: fixtureFileName,
}).as('getRoleDetails');

Expand All @@ -48,7 +48,7 @@ Cypress.Commands.add(
Cypress.Commands.add(
'mockInternalUsersAction',
function (fixtureFileName, funcMockedOn) {
cy.intercept(SEC_API_INTERNAL_USERS_PATH, {
cy.intercept(`${SEC_API_INTERNAL_USERS_PATH}*`, {
fixture: fixtureFileName,
}).as('getInternalUsersDetails');

Expand All @@ -61,7 +61,7 @@ Cypress.Commands.add(
Cypress.Commands.add(
'mockPermissionsAction',
function (fixtureFileName, funcMockedOn) {
cy.intercept(SEC_API_ACTIONGROUPS_PATH, {
cy.intercept(`${SEC_API_ACTIONGROUPS_PATH}*`, {
fixture: fixtureFileName,
}).as('getPermissions');

Expand All @@ -74,7 +74,7 @@ Cypress.Commands.add(
Cypress.Commands.add(
'mockTenantsAction',
function (fixtureFileName, funcMockedOn) {
cy.intercept(SEC_API_TENANTS_PATH, {
cy.intercept(`${SEC_API_TENANTS_PATH}*`, {
fixture: fixtureFileName,
}).as('getTenants');

Expand All @@ -87,7 +87,7 @@ Cypress.Commands.add(
Cypress.Commands.add(
'mockAuditLogsAction',
function (fixtureFileName, funcMockedOn) {
cy.intercept(SEC_API_AUDIT_PATH, {
cy.intercept(`${SEC_API_AUDIT_PATH}*`, {
fixture: fixtureFileName,
}).as('getAuditInfo');

Expand All @@ -101,7 +101,7 @@ Cypress.Commands.add(
'mockAuditConfigUpdateAction',
function (fixtureFileName, funcMockedOn) {
cy.intercept(
{ method: 'POST', url: SEC_API_AUDIT_CONFIG_PATH },
{ method: 'POST', url: `${SEC_API_AUDIT_CONFIG_PATH}*` },
{
fixture: fixtureFileName,
}
Expand All @@ -117,7 +117,7 @@ Cypress.Commands.add(
'mockCachePurgeAction',
function (fixtureFileName, funcMockedOn) {
cy.intercept(
{ method: 'DELETE', url: SEC_API_CACHE_PURGE_PATH },
{ method: 'DELETE', url: `${SEC_API_CACHE_PURGE_PATH}*` },
{
fixture: fixtureFileName,
}
Expand Down

0 comments on commit a2034d4

Please sign in to comment.