1 | // Test runner:
|
2 | const run = require('server/test/run');
|
3 |
|
4 | describe('Default modules', () => {
|
5 | it('can log the context', async () => {
|
6 | const res = await run(ctx => {
|
7 |
|
8 | try {
|
9 | require('util').inspect(ctx);
|
10 | } catch (err) {
|
11 | return err.message;
|
12 | }
|
13 | return 'Good!';
|
14 | }).get('/');
|
15 | expect(res.body).toBe('Good!');
|
16 | });
|
17 | });
|