From b61854b400e3d9e0d043cfec372a846076eaa261 Mon Sep 17 00:00:00 2001 From: RiteshHMCTS <74713687+RiteshHMCTS@users.noreply.github.com> Date: Wed, 20 Sep 2023 16:16:51 +0100 Subject: [PATCH] Revert "Bug/ex UI 855 mo nightly pipeline fix (#1101)" (#1104) This reverts commit 43faff86df62e11fe1df9fc99b94c2d85ee040a8. --- Jenkinsfile_nightly | 5 +++-- api/caaCases/caaCases.util.ts | 4 ---- api/caaCases/index.ts | 4 ++-- test/integration/tests/post_Invite_User.ts | 1 + test/integration/tests/post_ReInvite_User.ts | 1 - 5 files changed, 6 insertions(+), 9 deletions(-) diff --git a/Jenkinsfile_nightly b/Jenkinsfile_nightly index 5c6b55649..ef95f1f93 100644 --- a/Jenkinsfile_nightly +++ b/Jenkinsfile_nightly @@ -39,8 +39,9 @@ static LinkedHashMap secret(String secretName, String envVar) { withNightlyPipeline(type, product, component) { enableSlackNotifications(channel) loadVaultSecrets(secrets) - // enableFortifyScan('rpx-aat') - enableFullFunctionalTest(60) + enableFortifyScan('rpx-aat') + // enableFullFunctionalTest(60) + // enableSecurityScan() enableMutationTest() enableCrossBrowserTest() diff --git a/api/caaCases/caaCases.util.ts b/api/caaCases/caaCases.util.ts index 0b9ee10ad..816be06c0 100644 --- a/api/caaCases/caaCases.util.ts +++ b/api/caaCases/caaCases.util.ts @@ -80,10 +80,6 @@ export function getRequestBody(organisationID: string, pageNo: number, pageSize: }; } -export function validateCaseTypeId(caseTypeId: string): string { - return caseTypeId.match('^[0-9\\-_]+$') === null ? '' : caseTypeId; -} - function mapCcdData(ccdCase: CcdCase, columnConfigs: CcdColumnConfig[], caseType: string): any[] { const data = Array(); ccdCase.cases.forEach((caseData) => data.push(onGeneratedRow(caseData, columnConfigs, caseType))); diff --git a/api/caaCases/index.ts b/api/caaCases/index.ts index 97031e632..8ae54556b 100644 --- a/api/caaCases/index.ts +++ b/api/caaCases/index.ts @@ -2,12 +2,12 @@ import { NextFunction, Request, Response, Router } from 'express'; import { getConfigValue } from '../configuration'; import { SERVICES_MCA_PROXY_API_PATH, SERVICES_ROLE_ASSIGNMENT_API_PATH } from '../configuration/references'; import { EnhancedRequest } from '../models/enhanced-request.interface'; -import { getApiPath, getRequestBody, validateCaseTypeId, mapCcdCases } from './caaCases.util'; +import { getApiPath, getRequestBody, mapCcdCases } from './caaCases.util'; import { CaaCasesFilterType } from './enums'; import { RoleAssignmentResponse } from './models/roleAssignmentResponse'; export async function handleCaaCases(req: EnhancedRequest, res: Response, next: NextFunction) { - const caseTypeId = validateCaseTypeId(req.query.caseTypeId as string); + const caseTypeId = req.query.caseTypeId as string; const caaCasesPageType = req.query.caaCasesPageType as string; const caaCasesFilterType = req.query.caaCasesFilterType as string; const path = getApiPath(getConfigValue(SERVICES_MCA_PROXY_API_PATH), caseTypeId); diff --git a/test/integration/tests/post_Invite_User.ts b/test/integration/tests/post_Invite_User.ts index 5c9ec6d46..b36ec5e0d 100644 --- a/test/integration/tests/post_Invite_User.ts +++ b/test/integration/tests/post_Invite_User.ts @@ -17,5 +17,6 @@ suite('Manage Org -> POST Invite User', function() { // console.log('response', response.headers.get('cache-control')) .then((response) => { response.status.should.be.eql(200); + console.log(response); })); }); diff --git a/test/integration/tests/post_ReInvite_User.ts b/test/integration/tests/post_ReInvite_User.ts index 59bc61fdb..d9dd02db5 100644 --- a/test/integration/tests/post_ReInvite_User.ts +++ b/test/integration/tests/post_ReInvite_User.ts @@ -15,7 +15,6 @@ suite('Manage Org -> POST Re Invite User', function() { test('POST Invite User', () => generatePOSTAPIRequest('POST', '/api/inviteUser', payload) // console.log('response', response.headers.get('cache-control')) .then((response) => { - // console.log('response', response) if (response.status === 429) { console.log(`User Already Invited: ${response.status}`); }