From 21f67662425507988ad2e41247d2584f0951ed4d Mon Sep 17 00:00:00 2001 From: Kyle Date: Wed, 16 Oct 2024 13:36:23 -0700 Subject: [PATCH] fix filepath to test student data csv --- .../register-students/registerStudents.spec.cy.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/cypress/e2e/super-admin/default-tests/register-students/registerStudents.spec.cy.js b/cypress/e2e/super-admin/default-tests/register-students/registerStudents.spec.cy.js index 4f76ffbc1..2daf1fed3 100644 --- a/cypress/e2e/super-admin/default-tests/register-students/registerStudents.spec.cy.js +++ b/cypress/e2e/super-admin/default-tests/register-students/registerStudents.spec.cy.js @@ -2,6 +2,7 @@ import { navigateToPageFromMenubar } from '../../../../support/helper-functions/ const timeout = Cypress.env('timeout'); const selector = '.p-datatable-thead > tr > :nth-child'; +const filepath = 'cypress/fixtures/super-admin/testStudentData.csv'; // This function clicks the dropdown menu, which is indexed by int, then clicks the field. function selectField(int, fieldName) { @@ -26,7 +27,10 @@ describe( navigateToPageFromMenubar('Users', 'Register students'); - cy.get('input[type=file]').selectFile('cypress/fixtures/testStudentData.csv', { force: true, timeout: 10000 }); + cy.get('input[type=file]').selectFile(filepath, { + force: true, + timeout: 10000, + }); selectField(1, 'Student Username'); selectField(2, 'Password');