-
-
Notifications
You must be signed in to change notification settings - Fork 156
Convert tests to use supertest #398
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
Conversation
template/test/web/support.js
Outdated
| body: { email: 'test2@example.com', message: 'Test message!' } | ||
| }); | ||
| const { web } = t.context; | ||
| await global.web.post('/en/support') |
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.
☝️
|
Currently the snapshot tests fail every time because of the following error in the difference between snapshot and response. <script>␊
window.USER = {␊
- id: "ifv1MFasogj7xXQlho60bD6F420IXPK3"␊
+ id: "atZFh3BUUcJo4Fs8uWXmvHDKX_K7sk9l"␊
};␊
</script>␊ |
97c4998 to
fd5d6f5
Compare
fix: fixed tests (temporarily removed mandarin/markdown until lad v2 released)
Codecov Report
@@ Coverage Diff @@
## master #398 +/- ##
=======================================
Coverage 75.00% 75.00%
=======================================
Files 1 1
Lines 24 24
=======================================
Hits 18 18
Misses 6 6 Continue to review full report at Codecov.
|
| @@ -0,0 +1,51 @@ | |||
| // Necessary utils for testing | |||
| // Librarires required for testing | |||
| const MongodbMemoryServer = require('mongodb-memory-server').default; | |||
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.
👍
| test.before(before); | ||
| test.after.always(after); | ||
| test.beforeEach(beforeEach); | ||
| test.afterEach.always(afterEach); |
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.
👍
All tests should now use supertest instead of Frisbee.