From 94b249900dd96acace378a91ea5a3791eafa93e5 Mon Sep 17 00:00:00 2001 From: sbs20 Date: Fri, 3 Nov 2023 13:05:41 +0000 Subject: [PATCH] Test document Outlines a rough set of tests and therefore an intended scope of "support". --- README.md | 9 ++- _config.yml | 9 ++- docs/{90-development.md => 50-development.md} | 0 ...{91-localisation.md => 51-localisation.md} | 4 +- docs/60-testing.md | 74 +++++++++++++++++++ docs/{92-references.md => 90-references.md} | 0 docs/{93-qnap.md => 91-qnap.md} | 0 7 files changed, 86 insertions(+), 10 deletions(-) rename docs/{90-development.md => 50-development.md} (100%) rename docs/{91-localisation.md => 51-localisation.md} (92%) create mode 100644 docs/60-testing.md rename docs/{92-references.md => 90-references.md} (100%) rename docs/{93-qnap.md => 91-qnap.md} (100%) diff --git a/README.md b/README.md index 5f9e43c7..2ce169fc 100644 --- a/README.md +++ b/README.md @@ -108,10 +108,11 @@ It supports any ### Developing -* [Development](docs/90-development.md) -* [Localisation](docs/91-localisation.md) -* [References](docs/92-references.md) -* [QNAP](docs/93-qnap.md) +* [Development](docs/50-development.md) +* [Localisation](docs/51-localisation.md) +* [Testing](docs/60-testing.md) +* [References](docs/90-references.md) +* [QNAP](docs/91-qnap.md) ## Running scanservjs diff --git a/_config.yml b/_config.yml index d8980ffa..c31986ab 100644 --- a/_config.yml +++ b/_config.yml @@ -27,8 +27,9 @@ description: |-

Developing

    -
  1. Development
  2. -
  3. Localisation
  4. -
  5. References
  6. -
  7. QNAP
  8. +
  9. Development
  10. +
  11. Localisation
  12. +
  13. Testing
  14. +
  15. References
  16. +
  17. QNAP
diff --git a/docs/90-development.md b/docs/50-development.md similarity index 100% rename from docs/90-development.md rename to docs/50-development.md diff --git a/docs/91-localisation.md b/docs/51-localisation.md similarity index 92% rename from docs/91-localisation.md rename to docs/51-localisation.md index 8a8a4749..676cb58d 100644 --- a/docs/91-localisation.md +++ b/docs/51-localisation.md @@ -13,7 +13,7 @@ ready for localisation) and localisation (l10n, implementing specific locales). * Copy an existing locale, name it according to the iso 639 and sub region; see [w3c](https://www.w3.org/International/articles/language-tags/) * Update the translations -* If possible, test it works (see [development](./90-development.md)) +* If possible, test it works (see [development](./50-development.md)) * Raise a PR or attach it to a new issue or #154 * Add the locale name to the fallback locale [en](../app-ui/src/locales/en.json) under the "locales" key. @@ -31,6 +31,6 @@ Either an existing translation could be improved or is missing altogether. ## Finding missing translations -* Configure [development](./90-development.md) +* Configure [development](./50-development.md) * Run `npm run util:missing-translations` * This will output JSON with all the missing keys diff --git a/docs/60-testing.md b/docs/60-testing.md new file mode 100644 index 00000000..9bc1aa93 --- /dev/null +++ b/docs/60-testing.md @@ -0,0 +1,74 @@ +# Testing + +## Summary + +Where possible there are automated unit tests. These are built into the build +pipeline and can be run independently with `npm run test`. + +However, this app needs to run in all combinations of the following: + +### Architectures: + +* AMD64 +* ARM + +### Operating systems: + +* Debian 10 Buster +* Debian 11 Bullseye +* Debian 12 Bookworm +* Arch + +### Node versions + +* 10+ + +### Browsers + +* Not Internet Explorer + +### Mode + +* Container +* Native + * Installing DEB over legacy + * Upgrading DEB + +Where possible, the app has been designed to minimise the differences with all +permuations. + +* Docker builds a deb file and installs that +* Docker uses Debian 12 and Node 18 +* There are no known architecture differences + +Nonetheless there is a lot to cover. + +## Test plan + +Depending on the scope of change any of the following may be required. For a +major release, all tests should be run. For a minor one, the scope can be +reduced. + +### Application testing + +* Find scanners +* Test config overrides +* Preview +* Filters +* Any changed pipelines +* Scan +* Settings +* About and system info + +### Docker + +* Build the image +* Run the container +* Verify find scanners and system info + +### DEB + +* Verify install, remove +* Verify install, update +* Verify purge +* Run on Buster, Bullseye, Bookworm, RaspberryPi OS diff --git a/docs/92-references.md b/docs/90-references.md similarity index 100% rename from docs/92-references.md rename to docs/90-references.md diff --git a/docs/93-qnap.md b/docs/91-qnap.md similarity index 100% rename from docs/93-qnap.md rename to docs/91-qnap.md