diff --git a/integration-tests/integration/reportPages/enter-use-of-force-details.cy.js b/integration-tests/integration/reportPages/enter-use-of-force-details.cy.js index caa51fc6..89455977 100644 --- a/integration-tests/integration/reportPages/enter-use-of-force-details.cy.js +++ b/integration-tests/integration/reportPages/enter-use-of-force-details.cy.js @@ -37,7 +37,6 @@ context('Enter use of force details page', () => { useOfForceDetailsPage.escortingHold().check('true') useOfForceDetailsPage.restraintPositions.check(restraintPositions) useOfForceDetailsPage.handcuffsApplied().check('true') - useOfForceDetailsPage.painInducingTechniques().check('true') useOfForceDetailsPage.painInducingTechniquesUsed.check(['THUMB_LOCK', 'THROUGH_RIGID_BAR_CUFFS']) const relocationAndInjuriesPage = useOfForceDetailsPage.save() return relocationAndInjuriesPage @@ -63,7 +62,6 @@ context('Enter use of force details page', () => { personalProtectionTechniques: true, positiveCommunication: true, restraintPositions: ['STANDING', 'ON_BACK', 'FACE_DOWN', 'KNEELING'], - painInducingTechniques: true, painInducingTechniquesUsed: ['THROUGH_RIGID_BAR_CUFFS', 'THUMB_LOCK'], }) }) @@ -89,7 +87,6 @@ context('Enter use of force details page', () => { personalProtectionTechniques: true, positiveCommunication: true, restraintPositions: 'STANDING', - painInducingTechniques: true, painInducingTechniquesUsed: ['THROUGH_RIGID_BAR_CUFFS', 'THUMB_LOCK'], }) }) @@ -118,7 +115,8 @@ context('Enter use of force details page', () => { useOfForceDetailsPage.restraintPositions.kneeling().should('be.checked') useOfForceDetailsPage.restraintPositions.onBack().should('not.be.checked') useOfForceDetailsPage.handcuffsApplied().should('have.value', 'true') - useOfForceDetailsPage.painInducingTechniques().should('have.value', 'true') + useOfForceDetailsPage.painInducingTechniquesUsed.throughRigidBarCuffs().should('be.checked') + useOfForceDetailsPage.painInducingTechniquesUsed.thumbLock().should('be.checked') }) it('Displays validation messages', () => { @@ -139,9 +137,9 @@ context('Enter use of force details page', () => { useOfForceDetailsPage.guidingHoldOfficersInvolved.check('2') useOfForceDetailsPage.escortingHold().check('true') useOfForceDetailsPage.handcuffsApplied().check('true') - useOfForceDetailsPage.painInducingTechniques().check('true') useOfForceDetailsPage.clickSaveAndContinue() useOfForceDetailsPage.errorSummary().contains('Select yes if a baton was drawn') useOfForceDetailsPage.errorSummary().contains('Enter the body-worn camera number') + useOfForceDetailsPage.errorSummary().contains('Select if any pain inducing techniques were used') }) }) diff --git a/integration-tests/integration/seedData.js b/integration-tests/integration/seedData.js index 98c58307..f1c22811 100644 --- a/integration-tests/integration/seedData.js +++ b/integration-tests/integration/seedData.js @@ -33,7 +33,6 @@ const expectedPayload = { escortingHold: true, handcuffsApplied: true, restraintPositions: ['STANDING', 'ON_BACK', 'FACE_DOWN', 'KNEELING'], - painInducingTechniques: true, painInducingTechniquesUsed: ['FINAL_LOCK_FLEXION', 'THUMB_LOCK'], positiveCommunication: true, guidingHoldOfficersInvolved: 2, diff --git a/integration-tests/pages/createReport/useOfForceDetailsPage.js b/integration-tests/pages/createReport/useOfForceDetailsPage.js index a484390b..8e12ce99 100644 --- a/integration-tests/pages/createReport/useOfForceDetailsPage.js +++ b/integration-tests/pages/createReport/useOfForceDetailsPage.js @@ -35,7 +35,6 @@ const useOfForceDetailsPage = () => handcuffsApplied: () => cy.get('[name="handcuffsApplied"]'), - painInducingTechniques: () => cy.get('[name="painInducingTechniques"]'), painInducingTechniquesUsed: { check: value => cy.get('#pain-inducing-techniques [type="checkbox"]').check(value), thumbLock: () => cy.get('#pain-inducing-techniques [type="checkbox"][value="THUMB_LOCK"]'), @@ -47,6 +46,7 @@ const useOfForceDetailsPage = () => finalLockRotation: () => cy.get('#pain-inducing-techniques [type="checkbox"][value="FINAL_LOCK_ROTATION"]'), throughRigidBarCuffs: () => cy.get('#pain-inducing-techniques [type="checkbox"][value="THROUGH_RIGID_BAR_CUFFS"]'), + none: () => cy.get('#pain-inducing-techniques [type="checkbox"][value="NONE"]'), }, fillForm() { @@ -62,7 +62,6 @@ const useOfForceDetailsPage = () => this.escortingHold().check('true') this.restraintPositions.check(['STANDING', 'ON_BACK', 'FACE_DOWN', 'KNEELING']) this.handcuffsApplied().check('true') - this.painInducingTechniques().check('true') this.painInducingTechniquesUsed.check(['THUMB_LOCK', 'FINAL_LOCK_FLEXION']) }, diff --git a/integration-tests/pages/sections/reportDetails.js b/integration-tests/pages/sections/reportDetails.js index 47fec1b5..ce3df7f1 100644 --- a/integration-tests/pages/sections/reportDetails.js +++ b/integration-tests/pages/sections/reportDetails.js @@ -5,7 +5,6 @@ const positiveCommunicationUsed = () => cy.get('[data-qa="positiveCommunication" const handcuffsApplied = () => cy.get('[data-qa=handcuffsApplied]') const prisonerCompliant = () => cy.get('[data-qa="compliancy"]') const photosTaken = () => cy.get('[data-qa="photographs"]') -const painInducingTechniques = () => cy.get('[data-qa=painInducingTechniques]') const painInducingTechniquesUsed = () => cy.get('[data-qa=painInducingTechniquesUsed]') const reasonsForUseOfForce = () => cy.get('[data-qa="reasonsForUseOfForce"') const primaryReasonForUseOfForce = () => cy.get('[data-qa="primaryReason"') @@ -17,7 +16,6 @@ module.exports = { handcuffsApplied, prisonerCompliant, photosTaken, - painInducingTechniques, painInducingTechniquesUsed, prison, reasonsForUseOfForce, @@ -68,8 +66,7 @@ module.exports = { cy.get('[data-qa="restraintUsed"]').contains('On front (prone)') cy.get('[data-qa="restraintUsed"]').contains('Kneeling') handcuffsApplied().contains('Yes') - painInducingTechniques().contains('Yes') - cy.get('[data-qa="painInducingTechniques"]').contains('Yes - wrist flexion, thumb lock') + cy.get('[data-qa="painInducingTechniques"]').contains('Wrist flexion, thumb lock') cy.get('[data-qa="prisonerRelocation"]').contains('Segregation unit') prisonerCompliant().contains('Yes')