From ab988d95a57de89d1c2c708b0b394f52b003b017 Mon Sep 17 00:00:00 2001 From: Danny Gleckler Date: Wed, 26 Jul 2023 14:34:58 -0400 Subject: [PATCH] feat: Fix Firefox screenshots (#95) * Fix firefox screenshots * Swap map to forEach --- src/browser/vdiff.js | 3 +++ src/server/pause.js | 4 ++++ 2 files changed, 7 insertions(+) diff --git a/src/browser/vdiff.js b/src/browser/vdiff.js index 718bb886..4f2e9fa0 100644 --- a/src/browser/vdiff.js +++ b/src/browser/vdiff.js @@ -1,6 +1,9 @@ import { chai, expect } from '@open-wc/testing'; import { executeServerCommand } from '@web/test-runner-commands'; +// start loading fonts early +[...document.fonts].forEach(font => font.load()); + let test; /* eslint-disable no-undef, no-invalid-this */ diff --git a/src/server/pause.js b/src/server/pause.js index 40e8643a..3cfb1d5c 100644 --- a/src/server/pause.js +++ b/src/server/pause.js @@ -3,6 +3,10 @@ test.pause = new Promise(r => test.start = r); const controls = `