Fix #718 - Extension param now accept multiple extensions

This commit is contained in:
Faisal Salman
2024-06-06 20:02:22 +07:00
parent f7810dbfcf
commit 0a46ac396a
4 changed files with 32 additions and 10 deletions

View File

@@ -126,6 +126,13 @@ describe('Extending Regex', function () {
});
let myUA2 = 'Mozilla/5.0 MyTab 14 Pro Max';
assert.deepEqual(myParser2.setUA(myUA2).getDevice(), {vendor: "MyTab", model: "14 Pro Max", type: "tablet"});
let myParser3 = new UAParser([{
browser: myOwnListOfBrowsers
}, {
device: myOwnListOfDevices
}]);
assert.deepEqual(myParser3.setUA(myUA2).getDevice(), {vendor: "MyTab", model: "14 Pro Max", type: "tablet"});
});
describe('User-agent length', function () {