mirror of
https://github.com/tenrok/axios.git
synced 2026-05-15 11:59:42 +03:00
fix(Tests): updating regex to allow for pre-releases
This commit is contained in:
@@ -447,7 +447,7 @@ describe('supports http with nodejs', function () {
|
||||
res.end(req.headers['user-agent']);
|
||||
}).listen(4444, function () {
|
||||
axios.get('http://localhost:4444/').then(function (res) {
|
||||
assert.ok(/^axios\/[\d.]+$/.test(res.data), `User-Agent header does not match: ${res.data}`);
|
||||
assert.ok(/^axios\/[\d.]+[-]?[a-z]*[.]?[\d]+$/.test(res.data), `User-Agent header does not match: ${res.data}`);
|
||||
done();
|
||||
}).catch(done);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user