1
0
mirror of https://github.com/lancedikson/bowser synced 2024-10-27 20:34:22 +00:00

Fixed getSecondMatch test

This commit is contained in:
Oliver foster 2019-12-19 11:38:49 +00:00
parent 64bbd2a9b1
commit cad365b53e

View File

@ -21,7 +21,7 @@ test('getFirstMatch', (t) => {
});
test('getSecondMatch', (t) => {
const matchedVersion = getSecondMatch(/version\/(\S+)/ig, 'Chrome Version/11.11.11 Chrome Version/22.22.22');
const matchedVersion = getSecondMatch(/version\/(\S+).*version\/(\S+)/i, 'Chrome Version/11.11.11 Chrome Version/22.22.22');
t.is(matchedVersion, '22.22.22');
});