-
Notifications
You must be signed in to change notification settings - Fork 178
Conversation
Codecov Report
@@ Coverage Diff @@
## add/more-vue-query #2536 +/- ##
=======================================================
+ Coverage 26.15% 60.13% +33.98%
=======================================================
Files 210 181 -29
Lines 4252 3946 -306
Branches 657 715 +58
=======================================================
+ Hits 1112 2373 +1261
+ Misses 3140 1573 -1567
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
Regarding integration tests, I wonder if we should add the Cypress test framework? It seems to be recommended by Quasar: https://github.com/quasarframework/quasar-testing/blob/dev/packages/e2e-cypress/README.md EDIT: People on HN seem to recommend Playwright over Cypress: https://news.ycombinator.com/item?id=30083042 |
My current sense is to try and create integration tests that are not end to end tests. So, this sense of them from Kent C Dodds: The e2e testing tools are quite heavy. So, one idea, which I didn't yet explore further is something along the lines of:
The sense of the goals I have here are:
It might be that:
However, a bunch of things push integration tests more into e2e tooling. quasar-testing seems still being upgraded to v2, and lists unit testing (with jest) and e2e testing (with cypress), so the type of tests I'm talking about may not be very well supported by the tooling. |
a339e7a
to
b3728e5
Compare
027ead8
to
66b8d73
Compare
Very WIP!
eda232a
to
7b78e1c
Compare
using the fancy user-event library, as fireEvent would not handle the modal properly
just notifications for now, but we can aim to convert some more relevant stories (also fixed a surprising amount of bugs!)
not needed anymore due to different storyshots implementation
This is a change of testing approach, loosely based on Kent C. Dodds blog post Write tests. Not too many. Mostly integration.. The premise is that the tooling is good enough to write integration tests that run reliably, and are easy enough to write. The older paradigm of a bazillion unit tests was partly based on it being difficult to write integration tests. So, the new approach is: use https://testing-library.com which encourages higher level testing from the user perspective two types of tests: page-level tests (e.g. testing stuff in src/*/pages/*.vue) that load the page component but not the router App tests, that load the root App component and the router use the new mockBackend which mocks at the axios-layer, for all tests that need it Co-authored-by: Tilmann Becker <tilmann.becker@gmail.com>
This is a change of testing approach, loosely based on Kent C. Dodds blog post Write tests. Not too many. Mostly integration.. The premise is that the tooling is good enough to write integration tests that run reliably, and are easy enough to write. The older paradigm of a bazillion unit tests was partly based on it being difficult to write integration tests. So, the new approach is: use https://testing-library.com which encourages higher level testing from the user perspective two types of tests: page-level tests (e.g. testing stuff in src/*/pages/*.vue) that load the page component but not the router App tests, that load the root App component and the router use the new mockBackend which mocks at the axios-layer, for all tests that need it Co-authored-by: Tilmann Becker <tilmann.becker@gmail.com>
This PR is for https://community.karrot.world/t/nlnet-responsiblities/892 Add frontend integration tests and aim for 75% test coverage task.
This is a change of testing approach, loosely based on Kent C. Dodds blog post Write tests. Not too many. Mostly integration..
The premise is that the tooling is good enough to write integration tests that run reliably, and are easy enough to write. The older paradigm of a bazillion unit tests was partly based on it being difficult to write integration tests.
So, the new approach is:
src/*/pages/*.vue
) that load the page component but not the routerApp
tests, that load the rootApp
component and the routermockBackend
which mocks at the axios-layer, for all tests that need it