Skip to content

Commit

Permalink
chore: test
Browse files Browse the repository at this point in the history
  • Loading branch information
eirikhaugstulen committed Oct 20, 2023
1 parent bb177f9 commit 06f9bf1
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 17 deletions.
6 changes: 0 additions & 6 deletions cypress/e2e/ScopeSelector/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -232,12 +232,6 @@ Then('you are navigated to the search page with the same org unit and program Ch
cy.url().should('eq', `${Cypress.config().baseUrl}/#/search?orgUnitId=DiszpKrYNg8&programId=IpHINAT79UW`);
});

And('there should be Child Programme domain forms visible to search with', () => {
cy.get('[data-test="search-page-content"]')
.find('[data-test="capture-ui-input"]')
.should('have.length', 1);
});

const selectedChildProgram = ['Program', 'Child Programme'];
const selectedMalariaProgram = ['Program', 'Malaria case diagnosis'];
const selectedEventProgram = ['Program', 'Antenatal care visit'];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -459,7 +459,7 @@ Then('the admission filter should be in effect', () => {
// clean up
cy.get('@newEventResult')
.then((result) => {
expect(result.status).to.equal(201);
expect(result.response.statusCode).to.equal(201);
const id = result.response.body.response.uid;
cy.buildApiUrl('eventFilters', id)
.then((eventFiltersUrl) => {
Expand Down Expand Up @@ -495,8 +495,7 @@ When('you delete the name toDeleteWorkingList', () => {
.click();
cy.contains('Delete view')
.click();
cy.server();
cy.route('DELETE', '**/eventFilters/**').as('deleteEventFilters');
cy.intercept('DELETE', '**/eventFilters/**').as('deleteEventFilters');
cy.get('button')
.contains('Confirm')
.click();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -717,12 +717,6 @@ Then('the working list configuration was kept', () => {
.should('exist');
});

Then('the working list configuration was kept', () => {
cy.get('[data-test="tei-working-lists"]')
.contains('Event status: Completed')
.should('exist');
});

Then('the program stage custom working list filters are loaded', () => {
cy.get('[data-test="tei-working-lists"]')
.find('[data-test="more-filters"]')
Expand Down
3 changes: 1 addition & 2 deletions cypress/support/tagUtils/filterInstanceVersion.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,7 @@ export const filterInstanceVersion = (skip) => {
return false;
}

const test = operation[operator](currentInstanceVersion, version);
return test;
return operation[operator](currentInstanceVersion, version);
});

if (!shouldRun) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ type Props = {|
|}

const WithoutOrgUnitSelectedMessagePlain = ({ programId, setShowAccessible, classes }: Props) => {
// TODO - this hook breaks the app when the program is not found
const { program, programType } = useProgramInfo(programId);
const IncompleteSelectionMessage = useMemo(() => (programType === programTypes.TRACKER_PROGRAM ? (
i18n.t('Or see all records accessible to you in {{program}} ', {
Expand Down

0 comments on commit 06f9bf1

Please sign in to comment.