Test HTMLImageElement::decode() does not leak the pending promises after resolving or rejecting them. On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". Decoding a bitmap image - promises will be resolved: PASS internals.imagePendingDecodePromisesCountForTesting(image) is 0 Decoding a SVG image - promises will be resolved: PASS internals.imagePendingDecodePromisesCountForTesting(image) is 0 Decoding a broken image - promises will be rejected: PASS internals.imagePendingDecodePromisesCountForTesting(image) is 0 PASS successfullyParsed is true TEST COMPLETE