зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1729455 - Test that synchronization sources have a timestamp with the correct base. r=ng
Differential Revision: https://phabricator.services.mozilla.com/D128245
This commit is contained in:
Родитель
bdd63e9323
Коммит
f816c6f0c6
|
@ -45,9 +45,12 @@
|
|||
`Synchronization source audio level <= 1.0 (${source.audioLevel})`);
|
||||
ok(source.timestamp,
|
||||
`Synchronization source has timestamp (${source.timestamp})`);
|
||||
ok(window.performance.now() + window.performance.timeOrigin -
|
||||
source.timestamp < 2500, // This large value is used because sometimes
|
||||
// the testing hardware is _very_ slow
|
||||
const ageSeconds =
|
||||
(window.performance.now() + window.performance.timeOrigin -
|
||||
source.timestamp) / 1000;
|
||||
ok(ageSeconds >= 0,
|
||||
`Synchronization source timestamp is in the past`);
|
||||
ok(ageSeconds < 2.5,
|
||||
`Synchronization source timestamp is close to now`);
|
||||
is(source.voiceActivityFlag, undefined,
|
||||
"Synchronization source unsupported voiceActivity is undefined");
|
||||
|
|
Загрузка…
Ссылка в новой задаче