Skip to content

Commit e367155

Browse files
committed
fix: failing integration tests
1 parent 8864844 commit e367155

File tree

2 files changed

+11
-5
lines changed

2 files changed

+11
-5
lines changed

compose/neurosynth-frontend/cypress/e2e/workflows/Extraction/ExtractionTable.cy.tsx

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -154,24 +154,30 @@ describe('ExtractionTable', () => {
154154
});
155155
});
156156

157-
it('should remove the filter if the delete button is clicked', () => {
157+
it.only('should remove the filter if the delete button is clicked', () => {
158+
let studysetYear = '';
158159
// ARRANGE
159160
cy.wait('@studysetFixture').then((studysetFixture) => {
160161
const studyset = studysetFixture?.response?.body as StudysetReturn;
161162
const studysetStudies = studyset.studies as StudyReturn[];
163+
studysetYear = studysetStudies[0].year?.toString() || "";
162164
cy.get('input').eq(0).click();
163165
cy.get(`input`)
164166
.eq(0)
165167
.type(studysetStudies[0].year?.toString() || '');
166168
});
167169
cy.get('tbody > tr').should('have.length', 1);
168-
cy.get('[data-testid="CancelIcon"]').should('exist');
170+
169171
// ACT
170-
cy.get('[data-testid="CancelIcon"]').click();
172+
cy.contains(
173+
`Filtering YEAR: ${studysetYear}`
174+
).parent().find('[data-testid="CancelIcon"]').click();
171175

172176
// ASSERT
173177
cy.get('tbody > tr').should('have.length', 3);
174-
cy.get(`[data-testid="CancelIcon"]`).should('not.exist');
178+
cy.contains(
179+
`Filtering YEAR: ${studysetYear}`
180+
).should('not.exist')
175181
});
176182
});
177183

compose/neurosynth-frontend/cypress/e2e/workflows/SleuthImport/DoSleuthImport.cy.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -422,7 +422,7 @@ describe('DoSleuthImport', () => {
422422

423423
it('should select MKDA and create an MKDA meta analysis', () => {
424424
cy.contains('button', 'Yes').click();
425-
cy.get('[type="radio"]').eq(1).click();
425+
cy.get('[type="radio"]').eq(1).click({ force: true });
426426
cy.contains('button', 'create')
427427
.click()
428428
.wait('@specificationPostFixture')

0 commit comments

Comments
 (0)