dev:contributing:qa
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
dev:contributing:qa [2015/08/12 12:08] – [pgTAP Live Database Tests] yboston | dev:contributing:qa [2024/09/13 13:24] (current) – [C Unit Tests] add a tag sandbergja | ||
---|---|---|---|
Line 35: | Line 35: | ||
===== Types of Tests ===== | ===== Types of Tests ===== | ||
+ | |||
+ | ==== AngularJS Unit Tests ==== | ||
+ | |||
+ | These test the Web Client apps. | ||
+ | |||
+ | * They are stored in '' | ||
+ | * See the [[https:// | ||
+ | |||
+ | Running the tests: | ||
+ | * See the [[https:// | ||
+ | * Steps to run the tests as of Evergreen 3.1: | ||
+ | |||
+ | cd $EVERGREEN_ROOT/ | ||
+ | # fetch JS dependencies, | ||
+ | npm install | ||
+ | # build, run tests, concat+minify | ||
+ | npm run build-prod | ||
+ | npm run test | ||
+ | |||
+ | ==== Angular Unit Tests ==== | ||
+ | |||
+ | See [[dev: | ||
+ | |||
+ | To run on a running Evergreen server: | ||
+ | |||
+ | <code sh> | ||
+ | cd Open-ILS/ | ||
+ | npm run test | ||
+ | </ | ||
+ | |||
+ | ==== Angular e2e (end-to-end) Tests ==== | ||
+ | |||
+ | To run with a GUI: | ||
+ | |||
+ | <code sh> | ||
+ | cd Open-ILS/ | ||
+ | ng e2e | ||
+ | </ | ||
+ | |||
+ | To run without a GUI: | ||
+ | |||
+ | <code sh> | ||
+ | cd Open-ILS/ | ||
+ | MOZ_HEADLESS=1 ng e2e | ||
+ | </ | ||
+ | |||
+ | To run in Chrome instead of Firefox: | ||
+ | <code sh> | ||
+ | cd Open-ILS/ | ||
+ | npm install --save-dev chromedriver | ||
+ | ng e2e --env chrome # with the GUI | ||
+ | ng e2e --env chrome-headless # without the GUI | ||
+ | </ | ||
+ | |||
+ | For more tips and documentation, | ||
+ | |||
+ | ==== OPAC Javascript Unit Tests ==== | ||
+ | |||
+ | To run tests for the javascript in the OPAC: | ||
+ | <code sh> | ||
+ | cd Open-ILS/ | ||
+ | npm i && npm run test | ||
+ | </ | ||
==== Perl Unit Tests ==== | ==== Perl Unit Tests ==== | ||
Line 95: | Line 158: | ||
The " | The " | ||
+ | |||
+ | Install pgtap from source, the versions in Debian/ | ||
+ | |||
+ | * Download from - http:// | ||
+ | * Install Instructions - http:// | ||
+ | * Install the package for libtap-parser-sourcehandler-pgtap-perl which provides pg_prove. | ||
<code sh> | <code sh> | ||
- | sudo apt-get install pgtap # debian/ubuntu version | + | apt-get install |
psql -U evergreen [other DB connection params] -c " | psql -U evergreen [other DB connection params] -c " | ||
</ | </ | ||
Line 132: | Line 201: | ||
At time of writing, there is no equivalent to " | At time of writing, there is no equivalent to " | ||
+ | |||
+ | {{tag> |
dev/contributing/qa.1439395721.txt.gz · Last modified: 2022/02/10 13:34 (external edit)