feat(config): add configuration window (#70)

This commit is contained in:
2026-05-21 04:16:21 -07:00
committed by GitHub
parent a54f03f0cd
commit dc52bc2fba
287 changed files with 14507 additions and 8134 deletions
@@ -0,0 +1,33 @@
import assert from 'node:assert/strict';
import test from 'node:test';
import { reloadOverlayWindowsForYomitanContentScripts } from './yomitan-extension-overlay-reload';
test('reloadOverlayWindowsForYomitanContentScripts reloads only live overlay windows', () => {
const calls: string[] = [];
const windows = [
{
isDestroyed: () => false,
webContents: {
isDestroyed: () => false,
reload: () => calls.push('live'),
},
},
{
isDestroyed: () => true,
webContents: {
isDestroyed: () => false,
reload: () => calls.push('destroyed-window'),
},
},
{
isDestroyed: () => false,
webContents: {
isDestroyed: () => true,
reload: () => calls.push('destroyed-webcontents'),
},
},
];
assert.equal(reloadOverlayWindowsForYomitanContentScripts(windows), 1);
assert.deepEqual(calls, ['live']);
});