Skip to content

Commit

Permalink
solve merge conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
JavidSumra committed Nov 7, 2024
2 parents 97bb3f6 + c27f595 commit df35f72
Show file tree
Hide file tree
Showing 506 changed files with 6,507 additions and 7,288 deletions.
2 changes: 1 addition & 1 deletion .env
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,4 @@ ESLINT_NO_DEV_ERRORS=true
CARE_CDN_URL="https://egov-s3-facility-10bedicu.s3.amazonaws.com https://egov-s3-patient-data-10bedicu.s3.amazonaws.com http://localhost:4566"
REACT_ALLOWED_LOCALES="en,hi,ta,ml,mr,kn"

REACT_ENABLED_APPS="ohcnetwork/care_livekit_fe@main"
REACT_ENABLED_APPS=""
2 changes: 0 additions & 2 deletions .envrc

This file was deleted.

7 changes: 5 additions & 2 deletions .prettierrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,8 @@
"jsxSingleQuote": false,
"arrowParens": "always",
"tailwindFunctions": ["classNames"],
"plugins": ["prettier-plugin-tailwindcss"]
}
"importOrder": ["<THIRD_PARTY_MODULES>", "^@/lib/(.*)$", "^@/CAREUI/(.*)$", "^@/components/ui/(.*)$", "^@/components/(.*)$", "^@/hooks/(.*)$", "^@/common/(.*)$", "^@/(.*)$", "^[./]"],
"importOrderSeparation": true,
"importOrderSortSpecifiers": true,
"plugins": ["prettier-plugin-tailwindcss", "@trivago/prettier-plugin-sort-imports"]
}
3 changes: 1 addition & 2 deletions cypress.config.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { defineConfig } from "cypress";
import fs from "fs";
import cypressSplit from "cypress-split";
import fs from "fs";

export default defineConfig({
projectId: "wf7d2m",
Expand Down Expand Up @@ -30,7 +30,6 @@ export default defineConfig({
baseUrl: "http://localhost:4000",
retries: 2,
requestTimeout: 15000,
excludeSpecPattern: "**/*roles.cy.ts",
},
env: {
API_URL: process.env.REACT_CARE_API_URL ?? "http://localhost:9000",
Expand Down
13 changes: 7 additions & 6 deletions cypress/e2e/assets_spec/AssetHomepage.cy.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import { AssetSearchPage } from "../../pageobject/Asset/AssetSearch";
import { AssetQRScanPage } from "../../pageobject/Asset/AssetQRScan";
import { AssetPagination } from "../../pageobject/Asset/AssetPagination";
import { AssetFilters } from "../../pageobject/Asset/AssetFilters";
import { v4 as uuidv4 } from "uuid";

import { AssetPage } from "../../pageobject/Asset/AssetCreation";
import { AssetFilters } from "../../pageobject/Asset/AssetFilters";
import { AssetPagination } from "../../pageobject/Asset/AssetPagination";
import { AssetQRScanPage } from "../../pageobject/Asset/AssetQRScan";
import { AssetSearchPage } from "../../pageobject/Asset/AssetSearch";
import LoginPage from "../../pageobject/Login/LoginPage";
import { v4 as uuidv4 } from "uuid";

describe("Asset Tab", () => {
const assetSearchPage = new AssetSearchPage();
Expand All @@ -18,7 +19,7 @@ describe("Asset Tab", () => {
const serialNumber = Math.floor(Math.random() * 10 ** 10).toString();

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
7 changes: 4 additions & 3 deletions cypress/e2e/assets_spec/AssetsCreation.cy.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import { AssetPage } from "../../pageobject/Asset/AssetCreation";
import { v4 as uuidv4 } from "uuid";
import LoginPage from "../../pageobject/Login/LoginPage";

import { AssetPage } from "../../pageobject/Asset/AssetCreation";
import { AssetSearchPage } from "../../pageobject/Asset/AssetSearch";
import LoginPage from "../../pageobject/Login/LoginPage";

describe("Asset", () => {
const assetPage = new AssetPage();
Expand All @@ -11,7 +12,7 @@ describe("Asset", () => {
const serialNumber = Math.floor(Math.random() * 10 ** 10).toString();

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
6 changes: 3 additions & 3 deletions cypress/e2e/assets_spec/AssetsManage.cy.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { AssetPage } from "../../pageobject/Asset/AssetCreation";
import LoginPage from "../../pageobject/Login/LoginPage";
import { AssetFilters } from "../../pageobject/Asset/AssetFilters";
import { AssetSearchPage } from "../../pageobject/Asset/AssetSearch";
import FacilityPage from "../../pageobject/Facility/FacilityCreation";
import { AssetFilters } from "../../pageobject/Asset/AssetFilters";
import LoginPage from "../../pageobject/Login/LoginPage";

function addDaysToDate(numberOfDays: number) {
const inputDate = new Date();
Expand All @@ -22,7 +22,7 @@ describe("Asset", () => {
const initiallocationName = "Camera Location";

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
19 changes: 0 additions & 19 deletions cypress/e2e/auth_spec/roles.cy.ts

This file was deleted.

4 changes: 2 additions & 2 deletions cypress/e2e/facility_spec/FacilityCreation.cy.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import FacilityPage from "../../pageobject/Facility/FacilityCreation";
import LoginPage from "../../pageobject/Login/LoginPage";
import FacilityHome from "../../pageobject/Facility/FacilityHome";
import LoginPage from "../../pageobject/Login/LoginPage";
import ManageUserPage from "../../pageobject/Users/ManageUserPage";
import { UserCreationPage } from "../../pageobject/Users/UserCreation";

Expand Down Expand Up @@ -59,7 +59,7 @@ describe("Facility Creation", () => {
const triageErrorMessage = ["This field is required"];

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
9 changes: 4 additions & 5 deletions cypress/e2e/facility_spec/FacilityHomepage.cy.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
// FacilityCreation

import LoginPage from "../../pageobject/Login/LoginPage";
import { AssetPagination } from "../../pageobject/Asset/AssetPagination";
import FacilityPage from "../../pageobject/Facility/FacilityCreation";
import FacilityHome from "../../pageobject/Facility/FacilityHome";
import LoginPage from "../../pageobject/Login/LoginPage";
import ManageUserPage from "../../pageobject/Users/ManageUserPage";
import FacilityPage from "../../pageobject/Facility/FacilityCreation";
import { UserPage } from "../../pageobject/Users/UserSearch";
import { AssetPagination } from "../../pageobject/Asset/AssetPagination";

describe("Facility Homepage Function", () => {
const loginPage = new LoginPage();
Expand All @@ -25,7 +24,7 @@ describe("Facility Homepage Function", () => {
const facilityType = "Private Hospital";

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
4 changes: 2 additions & 2 deletions cypress/e2e/facility_spec/FacilityInventory.cy.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import FacilityPage from "../../pageobject/Facility/FacilityCreation";
import LoginPage from "../../pageobject/Login/LoginPage";
import FacilityHome from "../../pageobject/Facility/FacilityHome";
import LoginPage from "../../pageobject/Login/LoginPage";

describe("Inventory Management Section", () => {
const facilityPage = new FacilityPage();
Expand All @@ -9,7 +9,7 @@ describe("Inventory Management Section", () => {
const inventoryName = "PPE";

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
9 changes: 5 additions & 4 deletions cypress/e2e/facility_spec/FacilityManage.cy.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
import LoginPage from "../../pageobject/Login/LoginPage";
import FacilityManage from "../../pageobject/Facility/FacilityManage";
import FacilityPage from "../../pageobject/Facility/FacilityCreation";
import { v4 as uuidv4 } from "uuid";

import FacilityPage from "../../pageobject/Facility/FacilityCreation";
import FacilityManage from "../../pageobject/Facility/FacilityManage";
import LoginPage from "../../pageobject/Login/LoginPage";

describe("Facility Manage Functions", () => {
const loginPage = new LoginPage();
const facilityManage = new FacilityManage();
Expand All @@ -26,7 +27,7 @@ describe("Facility Manage Functions", () => {
const currentUpdatedOccupied = "100";

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
4 changes: 2 additions & 2 deletions cypress/e2e/patient_spec/PatientBedManagement.cy.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import LoginPage from "../../pageobject/Login/LoginPage";
import { PatientConsultationPage } from "../../pageobject/Patient/PatientConsultation";
import { PatientPage } from "../../pageobject/Patient/PatientCreation";
import PatientLogupdate from "../../pageobject/Patient/PatientLogupdate";
import { PatientConsultationPage } from "../../pageobject/Patient/PatientConsultation";

describe("Patient swtich bed functionality", () => {
const loginPage = new LoginPage();
Expand All @@ -15,7 +15,7 @@ describe("Patient swtich bed functionality", () => {
const switchPatientTwo = "Dummy Patient 7";

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
12 changes: 6 additions & 6 deletions cypress/e2e/patient_spec/PatientConsultationCreation.cy.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
import LoginPage from "../../pageobject/Login/LoginPage";
import { PatientPage } from "../../pageobject/Patient/PatientCreation";
import { PatientConsultationPage } from "../../pageobject/Patient/PatientConsultation";
import PatientPredefined from "../../pageobject/Patient/PatientPredefined";
import ShiftCreation from "../../pageobject/Shift/ShiftCreation";
import PatientInvestigation from "../../pageobject/Patient/PatientInvestigation";
import PatientTreatmentPlan from "../../pageobject/Patient/PatientTreatmentPlan";
import { PatientPage } from "../../pageobject/Patient/PatientCreation";
import PatientDeathReport from "../../pageobject/Patient/PatientDeathReport";
import PatientInvestigation from "../../pageobject/Patient/PatientInvestigation";
import PatientPredefined from "../../pageobject/Patient/PatientPredefined";
import PatientPrescription from "../../pageobject/Patient/PatientPrescription";
import PatientTreatmentPlan from "../../pageobject/Patient/PatientTreatmentPlan";
import ShiftCreation from "../../pageobject/Shift/ShiftCreation";

describe("Patient Consultation in multiple combination", () => {
const patientConsultationPage = new PatientConsultationPage();
Expand Down Expand Up @@ -38,7 +38,7 @@ describe("Patient Consultation in multiple combination", () => {
const patientIpNumber = `${Math.floor(Math.random() * 90 + 10)}/${Math.floor(Math.random() * 9000 + 1000)}`;

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ describe("Patient Discharge based on multiple reason", () => {
const doctorName = "Custom Doctor";

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
3 changes: 2 additions & 1 deletion cypress/e2e/patient_spec/PatientDoctorConnect.cy.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { DoctorConnect } from "pageobject/Patient/PatientDoctorConnect";

import LoginPage from "../../pageobject/Login/LoginPage";
import { PatientPage } from "../../pageobject/Patient/PatientCreation";

Expand All @@ -12,7 +13,7 @@ describe("Patient Doctor Connect in consultation page", () => {
const teleIcuUser = "Dev Doctor Two";

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
2 changes: 1 addition & 1 deletion cypress/e2e/patient_spec/PatientDoctorNotes.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ describe("Patient Discussion notes in the consultation page", () => {
const discussionNotesSuccessMessage = "Note added successfully";

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
5 changes: 3 additions & 2 deletions cypress/e2e/patient_spec/PatientFileUpload.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import LoginPage from "../../pageobject/Login/LoginPage";
import { PatientPage } from "../../pageobject/Patient/PatientCreation";
import { PatientFileUpload } from "../../pageobject/Patient/PatientFileupload";

const loginPage = new LoginPage();
const patientPage = new PatientPage();
const patientFileUpload = new PatientFileUpload();
Expand All @@ -17,7 +18,7 @@ function runTests(
const patientNameTwo = "Dummy Patient 4";
const patientNameThree = "Dummy Patient 5";
before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down Expand Up @@ -90,7 +91,7 @@ function runTests(
patientFileUpload.verifyUploadFilePresence(newFileName);
patientFileUpload.verifyFileRenameOption(false);
// Login as District Admin
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.reload();
// Verify the file edit option is available
patientFileUpload.verifyUploadFilePresence(newFileName);
Expand Down
2 changes: 1 addition & 1 deletion cypress/e2e/patient_spec/PatientHomepage.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ describe("Patient Homepage present functionalities", () => {
const patientToDateBadge = "2023-12-07";

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
4 changes: 2 additions & 2 deletions cypress/e2e/patient_spec/PatientLogUpdate.cy.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import LoginPage from "../../pageobject/Login/LoginPage";
import { PatientConsultationPage } from "../../pageobject/Patient/PatientConsultation";
import { PatientPage } from "../../pageobject/Patient/PatientCreation";
import PatientLogupdate from "../../pageobject/Patient/PatientLogupdate";
import PatientInvestigation from "../../pageobject/Patient/PatientInvestigation";
import PatientLogupdate from "../../pageobject/Patient/PatientLogupdate";
import PatientPrescription from "../../pageobject/Patient/PatientPrescription";

describe("Patient Log Update in Normal, Critical and TeleIcu", () => {
Expand Down Expand Up @@ -41,7 +41,7 @@ describe("Patient Log Update in Normal, Critical and TeleIcu", () => {
const domicilaryPatient = "Dummy Patient 11";

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
4 changes: 2 additions & 2 deletions cypress/e2e/patient_spec/PatientPrescription.cy.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import PatientPrescription from "../../pageobject/Patient/PatientPrescription";
import LoginPage from "../../pageobject/Login/LoginPage";
import { PatientPage } from "../../pageobject/Patient/PatientCreation";
import PatientPrescription from "../../pageobject/Patient/PatientPrescription";

const patientPrescription = new PatientPrescription();
const loginPage = new LoginPage();
Expand All @@ -15,7 +15,7 @@ const medicineIndicator = "Test Indicator";

describe("Patient Medicine Administration", () => {
before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
8 changes: 4 additions & 4 deletions cypress/e2e/patient_spec/PatientRegistration.cy.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import FacilityPage from "../../pageobject/Facility/FacilityCreation";
import LoginPage from "../../pageobject/Login/LoginPage";
import { PatientPage } from "../../pageobject/Patient/PatientCreation";
import FacilityPage from "../../pageobject/Facility/FacilityCreation";
import { generatePhoneNumber } from "../../pageobject/utils/constants";
import PatientTransfer from "../../pageobject/Patient/PatientTransfer";
import PatientInsurance from "../../pageobject/Patient/PatientInsurance";
import PatientMedicalHistory from "../../pageobject/Patient/PatientMedicalHistory";
import PatientTransfer from "../../pageobject/Patient/PatientTransfer";
import { generatePhoneNumber } from "../../pageobject/utils/constants";

const yearOfBirth = "2001";
const isHCXEnabled = Cypress.env("ENABLE_HCX");
Expand Down Expand Up @@ -71,7 +71,7 @@ describe("Patient Creation with consultation", () => {
const patientOccupation = "Student";

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
4 changes: 2 additions & 2 deletions cypress/e2e/resource_spec/ResourcesHomepage.cy.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import FacilityPage from "../../pageobject/Facility/FacilityCreation";
import LoginPage from "../../pageobject/Login/LoginPage";
import ResourcePage from "../../pageobject/Resource/ResourcePage";
import FacilityPage from "../../pageobject/Facility/FacilityCreation";

describe("Resource Page", () => {
let createdResource: string;
Expand All @@ -10,7 +10,7 @@ describe("Resource Page", () => {
const phone_number = "9999999999";

before(() => {
loginPage.loginAsDisctrictAdmin();
loginPage.loginAsDistrictAdmin();
cy.saveLocalStorage();
});

Expand Down
Loading

0 comments on commit df35f72

Please sign in to comment.