update jsdom dependency, fix tests

This commit is contained in:
El RIDO 2025-02-11 08:08:18 +01:00
parent e4d1f4a26d
commit 64b0e33574
No known key found for this signature in database
GPG key ID: 0F5C940A6BD81F92
4 changed files with 141 additions and 141 deletions

View file

@ -66,7 +66,10 @@ describe('Check', function () {
'url': (secureProtocol ? 'https' : 'http' ) + '://' + domain.join('') + '/'
}
);
window.crypto = new WebCrypto();
Object.defineProperty(window, 'crypto', {
value: new WebCrypto(),
writeable: false,
});
Legacy.Check.init();
const result1 = Legacy.Check.getInit() && Legacy.Check.getStatus(),
result2 = secureProtocol === (document.getElementById('httpnotice').className === 'hidden');