User Tools

Site Tools


dev:contributing:qa

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
dev:contributing:qa [2025/06/27 15:36] – [Angular Unit Tests] add common things that break them sandbergjadev:contributing:qa [2025/09/09 14:55] (current) – lint section sleary
Line 53: Line 53:
   npm run build-prod   # may not be necessary for running tests   npm run build-prod   # may not be necessary for running tests
   npm run test   npm run test
 +
 +==== Angular Lint ====
 +
 +See ''Open-ILS/src/eg2/eslint.config.mjs'' for the current lint rules.
 +
 +To run on a running Evergreen server:
 +
 +<code sh>
 +cd Open-ILS/src/eg2
 +ng lint
 +</code>
 +
 +To fix syntax errors automatically:
 +
 +<code sh>
 +cd Open-ILS/src/eg2
 +ng lint --fix
 +</code>
 +
 +We also have several [[https://github.com/angular-eslint/angular-eslint/blob/main/docs/WRITING_CUSTOM_RULES.md|custom lint rules]].
 +
 +You can check out [[https://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/sleary/WIPs/lint-template|this template branch]] and follow the instructions in index.js to create a new custom lint rule.
  
 ==== Angular Unit Tests ==== ==== Angular Unit Tests ====
Line 86: Line 108:
  
 To fix it: You may be able to add a setTimeout.  Or use Angular's fakeAsync and tick. To fix it: You may be able to add a setTimeout.  Or use Angular's fakeAsync and tick.
 +
 ==== Angular e2e (end-to-end) Tests ==== ==== Angular e2e (end-to-end) Tests ====
  
dev/contributing/qa.txt · Last modified: 2025/09/09 14:55 by sleary

Except where otherwise noted, content on this wiki is licensed under the following license: CC Attribution-Share Alike 4.0 International
CC Attribution-Share Alike 4.0 International Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki

© 2008-2022 GPLS and others. Evergreen is open source software, freely licensed under GNU GPLv2 or later.
The Evergreen Project is a U.S. 501(c)3 non-profit organization.