Skip to content

Commit

Permalink
Merge branch 'main' into bob/fix-footer-fill
Browse files Browse the repository at this point in the history
  • Loading branch information
fzhao99 authored Dec 5, 2024
2 parents a0e4868 + 3cf8c43 commit 300c93d
Show file tree
Hide file tree
Showing 16 changed files with 6,366 additions and 12,648 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ repos:
name: Pretty Format JSON
args: [--autofix, --no-sort-keys]
- repo: https://github.com/pre-commit/mirrors-eslint
rev: "v9.15.0"
rev: "v9.16.0"
hooks:
- id: eslint
name: ESLint
Expand Down
1 change: 1 addition & 0 deletions query-connector/.env.sample
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@ AUTH_SECRET="ido5D/uybeAB3AmMQwn+ubw2zYC4t2h7RJlW2R79598="
AUTH_KEYCLOAK_ID=query-connector
AUTH_KEYCLOAK_SECRET=ZG3f7R1J3qIwBaw8QtttJnJMinpERQKs
AUTH_KEYCLOAK_ISSUER=http://localhost:8081/realms/master
E2E_LOCAL_FHIR_SERVER=http://localhost:8080/fhir
ERSD_API_KEY=
UMLS_API_KEY=
6 changes: 6 additions & 0 deletions query-connector/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,12 @@ If the above doesn't work, try replacing `localhost` with `0.0.0.0`.
4. Enter the DB password when prompted.
5. The extract file, `vs_dump.sql`, should now be created. It should automatically be located in `/query-connector`, but if it isn't, put `vs_dump.sql` there.

#### Running the e2e tests locally

Our e2e's are available locally via `npm run test:playright:local`. You'll need to have the app running locally at `localhost:3000` first (ie using `npm run dev`).

You'll need to set `E2E_LOCAL_FHIR_SERVER` in your local `.env` file first in order for the flows that use the local HAPI server to route correctly. This is pre-set for you in the `.env.sample` file.

### Architecture Diagram

```mermaid
Expand Down
9 changes: 4 additions & 5 deletions query-connector/e2e/customize_query.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,15 +54,14 @@ test.describe("querying with the Query Connector", () => {
await page.getByRole("link", { name: "Medications" }).click();
await page.getByRole("button", { name: "Chlamydia Medication" }).click();
await page
.getByRole("row")
.filter({ hasText: "azithromycin 1000 MG" })
.getByRole("img")
.getByRole("row", { name: "azithromycin 1000 MG" })
.locator("label")
.click();
await expect(page.getByText("3 of 4 selected")).toBeVisible();
await page
.getByRole("row")
.filter({ hasText: "ceftriaxone 500 MG Injection" })
.getByRole("img")
.locator("label")
.click();
await expect(page.getByText("2 of 4 selected")).toBeVisible();
await page.getByRole("button", { name: "Apply changes" }).click();
Expand Down Expand Up @@ -124,7 +123,7 @@ test.describe("querying with the Query Connector", () => {
await page.getByRole("link", { name: "Medications" }).click();
await page
.getByRole("button", { name: "Chlamydia Medication" })
.getByRole("img")
.locator("label")
.click();
await expect(page.getByText("0 of 4 selected")).toBeVisible();

Expand Down
Loading

0 comments on commit 300c93d

Please sign in to comment.