UNPKG

364 BJavaScriptView Raw
1// Test runner:
2const run = require('server/test/run');
3
4describe('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});