New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add guide on unit testing #6361
Conversation
Codecov Report
@@ Coverage Diff @@
## master #6361 +/- ##
=======================================
Coverage 19.87% 19.87%
=======================================
Files 856 856
Lines 12061 12061
Branches 1956 1956
=======================================
Hits 2397 2397
Misses 8085 8085
Partials 1579 1579
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Guide updated as well as my example
docs/v3.x/guides/unit-testing.md
Outdated
``` | ||
|
||
Those will inform `Jest` not to look for test inside the folder where it shouldn't. | ||
:::: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This end the tab.
But this should be used just after the npm
command.
Few lines before.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed now
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tab changes
Tab ends wrong place
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, everything works fine
I'm a getting a 403 status when trying to test a Public endpoint |
@sa-ma : did you get rid off that? |
Seems you're missing saving to I've written and post about this Allowing roles for test routes |
I stumbled upon your articles, very useful thanks @qunabu 🙏 |
Description of what you did:
Improved version of #6324
Documentation update on unit testing based on my medium post https://medium.com/qunabu-interactive/strapi-jest-testing-with-gitlab-ci-82ffe4c5715a.
Sample repository to that includes the examples from the guide https://github.com/qunabu/strapi-unit-test-example