From db1cbd293c11b13440b3e55de0f9212bbfc50449 Mon Sep 17 00:00:00 2001 From: kdaud Date: Tue, 4 Jun 2024 16:15:36 +0300 Subject: [PATCH] Test ERPNext-O3 flows --- .env | 2 +- e2e/tests/erpnext-openmrs-flows.spec.ts | 4 ++-- package.json | 2 +- playwright.config.ts | 4 +++- 4 files changed, 7 insertions(+), 5 deletions(-) diff --git a/.env b/.env index c43af12b..ae96baae 100644 --- a/.env +++ b/.env @@ -21,7 +21,7 @@ O3_URL_DEMO=https://demo.ozone-his.com # ERPNEXT ERPNEXT_URL_DEV=https://erpnext.ozone-dev.mekomsolutions.net -ERPNEXT_URL_QA= +ERPNEXT_URL_QA=https://erpnext.ozone-qa.mekomsolutions.net ERPNEXT_URL_DEMO= # Odoo diff --git a/e2e/tests/erpnext-openmrs-flows.spec.ts b/e2e/tests/erpnext-openmrs-flows.spec.ts index f5a09db8..f27fef62 100644 --- a/e2e/tests/erpnext-openmrs-flows.spec.ts +++ b/e2e/tests/erpnext-openmrs-flows.spec.ts @@ -47,7 +47,7 @@ test('Ordering a drug for an OpenMRS patient creates the corresponding ERPNext c await openmrs.voidPatient(); await erpnext.deleteQuotation(); }); - +/* test('Ending an OpenMRS patient visit with a synced drug order updates the corresponding ERPNext draft quotation to an open state.', async ({ page }) => { // setup await openmrs.createDrugOrder(); @@ -135,7 +135,7 @@ test('Discontinuing a synced OpenMRS drug order for an ERPNext customer with a s await expect(page.getByText('No Quotation found')).toBeVisible(); await openmrs.voidPatient(); }); - +*/ test.afterEach(async ({ page }) => { await erpnext.deleteCustomer(); await page.close(); diff --git a/package.json b/package.json index 37eaab37..bcb2d95c 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,7 @@ "!playwright-report/" ], "scripts": { - "e2e-tests-pro": "npx playwright test", + "e2e-tests-pro": "npx playwright test erpnext-openmrs", "e2e-tests-foss": "npx playwright test odoo-openmrs erpnext-openmrs openmrs-senaite" }, "publishConfig": { diff --git a/playwright.config.ts b/playwright.config.ts index f7e15c96..8d598a35 100644 --- a/playwright.config.ts +++ b/playwright.config.ts @@ -23,7 +23,9 @@ const config: PlaywrightTestConfig = { name: 'chromium', use: { ...devices['Desktop Chromium'], - viewport: { width: 1920, height: 1080 } + viewport: { width: 1920, height: 1080 }, + screenshot: 'only-on-failure', + video: 'on' }, },