|
|
|
@ -3,6 +3,8 @@ import {
|
|
|
|
|
getBrowserAlias,
|
|
|
|
|
getFirstMatch,
|
|
|
|
|
getWindowsVersionName,
|
|
|
|
|
getMacOSVersionName,
|
|
|
|
|
getAndroidVersionName,
|
|
|
|
|
compareVersions,
|
|
|
|
|
} from '../../src/utils';
|
|
|
|
|
|
|
|
|
@ -16,6 +18,17 @@ test('getWindowsVersionName', (t) => {
|
|
|
|
|
t.is(getWindowsVersionName('XXX'), void 0);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
test('getMacOSVersionName', (t) => {
|
|
|
|
|
t.is(getMacOSVersionName('10.14.5'), 'Mojave');
|
|
|
|
|
t.is(getMacOSVersionName('XXX'), void 0);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
test('getAndroidVersionName', (t) => {
|
|
|
|
|
t.is(getAndroidVersionName('8.0'), 'Oreo');
|
|
|
|
|
t.is(getAndroidVersionName('9'), 'Pie');
|
|
|
|
|
t.is(getWindowsVersionName('XXX'), void 0);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
test('compareVersions', (t) => {
|
|
|
|
|
const comparisionsTasks = [
|
|
|
|
|
['9.0', '10', -1],
|
|
|
|
|