attach ignore options to test app, w/ matching routes

This commit is contained in:
Luke Edwards
2018-07-29 14:02:18 -07:00
parent 51b4f9cbbf
commit 3d77dacbd6

View File

@@ -91,8 +91,14 @@ const middlewares = [
return new Store({ return new Store({
title: 'Stored title' title: 'Stored title'
}); });
} },
}) ignore: [
/foo/i,
'/buzz',
'fizz',
x => x === '/hello'
]
}),
]; ];
if (BASEPATH) { if (BASEPATH) {
@@ -101,4 +107,8 @@ if (BASEPATH) {
app.use(...middlewares); app.use(...middlewares);
} }
app.listen(PORT); ['foobar', 'buzz', 'fizzer', 'hello'].forEach(uri => {
app.get('/'+uri, (req, res) => res.end(uri));
});
app.listen(PORT);