ChRIS_ui icon indicating copy to clipboard operation
ChRIS_ui copied to clipboard

Local testing

Open jennydaman opened this issue 1 year ago • 2 comments

https://github.com/FNNDSC/miniChRIS-docker is added to this repository as a git submodule, and its startup/shutdown/management commands are added as npm scripts. For example, run npm run minichris:up to run miniChRIS, npm run minichris:down to shut down miniChRIS, npm run chrisomatic to run chrisomatic. Furthermore, scripts for downloading example DICOM data and the testing/chrisomatic.yml were added to this repository. This sets up everything we need to run tests of ChRIS_ui locally.

The command npm run dev:public was unchanged. The command npm run dev:local now does much more. Previously, all it did was run vite. Now, the npm run dev:local command will (1) run miniChRIS, (2) download sample DICOMs and add them to Orthanc, (3) wipe CUBE's PACSFiles table and delete all DICOM data from CUBE storage.

A new command was added: npm run test:e2e:local will run Playwright end-to-end tests, but against a local CUBE instead of using the public testing server. I added a test tests/pacsQueryAndRetrieve.spec.ts which only works against the local CUBE. It tests the PACS Q/R page.

jennydaman avatar Jul 22 '24 16:07 jennydaman

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 32.90%. Comparing base (f1d235a) to head (37894cf). Report is 2 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1229      +/-   ##
==========================================
+ Coverage   28.17%   32.90%   +4.72%     
==========================================
  Files         194      194              
  Lines        6349     6400      +51     
  Branches     1314     1330      +16     
==========================================
+ Hits         1789     2106     +317     
+ Misses       4451     4165     -286     
- Partials      109      129      +20     
Flag Coverage Δ
e2etests ?
e2etests-local 27.18% <ø> (?)
e2etests-public 27.64% <ø> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov-commenter avatar Jul 22 '24 17:07 codecov-commenter

I forgot about the dependencies on make, parallel, and curl. In the future, I’ll re-implement the helper scripts in TS so everything works cross-platform.

jennydaman avatar Jul 23 '24 14:07 jennydaman