mirror of
https://github.com/4gray/iptvnator.git
synced 2026-10-15 13:46:16 -08:00
chore(test): clean lint and warning baseline
This commit is contained in:
1 parent
3d4d2ca9bf
commit
a1b0d9186c
9 files changed
+154
-60
No files matched your search
+19
-14
@@ -1,26 +1,31 @@
|
||||
import { setupZoneTestEnv } from 'jest-preset-angular/setup-env/zone/index.mjs';
|
||||
import { installDuplicateVideoJsQualityLevelsWarnFilter } from '@iptvnator/shared/testing';
|
||||
|
||||
Object.defineProperty(globalThis, 'jest', {
|
||||
configurable: true,
|
||||
value: import.meta.jest,
|
||||
configurable: true,
|
||||
value: import.meta.jest,
|
||||
});
|
||||
|
||||
if (typeof (globalThis as { IDBFactory?: unknown }).IDBFactory === 'undefined') {
|
||||
Object.defineProperty(globalThis, 'IDBFactory', {
|
||||
configurable: true,
|
||||
value: class MockIDBFactory {},
|
||||
});
|
||||
if (
|
||||
typeof (globalThis as { IDBFactory?: unknown }).IDBFactory === 'undefined'
|
||||
) {
|
||||
Object.defineProperty(globalThis, 'IDBFactory', {
|
||||
configurable: true,
|
||||
value: class MockIDBFactory {},
|
||||
});
|
||||
}
|
||||
|
||||
if (!Element.prototype.animate) {
|
||||
Element.prototype.animate = () =>
|
||||
({
|
||||
cancel: () => undefined,
|
||||
finished: Promise.resolve(),
|
||||
}) as unknown as Animation;
|
||||
Element.prototype.animate = () =>
|
||||
({
|
||||
cancel: () => undefined,
|
||||
finished: Promise.resolve(),
|
||||
}) as unknown as Animation;
|
||||
}
|
||||
|
||||
installDuplicateVideoJsQualityLevelsWarnFilter();
|
||||
|
||||
setupZoneTestEnv({
|
||||
errorOnUnknownElements: true,
|
||||
errorOnUnknownProperties: true,
|
||||
errorOnUnknownElements: true,
|
||||
errorOnUnknownProperties: true,
|
||||
});
|
||||
Reference in new issue
Block a user