mirror of
https://github.com/ksyasuda/SubMiner.git
synced 2026-11-22 16:46:10 -08:00
test: cut low-value tests, rewrite the rest around behavior, parallelize lanes (#285)
This commit is contained in:
1 parent
4b6842d034
commit
b48083ddd8
368 files changed
+18045
-60331
No files matched your search
@@ -11,6 +11,7 @@ export interface YomitanAnkiServerSyncRuntimeDeps {
|
||||
getYomitanParserRuntimeDeps: () => Parameters<typeof syncYomitanDefaultAnkiServerCore>[1];
|
||||
logError: (message: string, ...args: unknown[]) => void;
|
||||
logInfo: (message: string, ...args: unknown[]) => void;
|
||||
syncDefaultAnkiServer?: typeof syncYomitanDefaultAnkiServerCore;
|
||||
}
|
||||
|
||||
export function buildYomitanAnkiSettingsKey(options: {
|
||||
@@ -25,6 +26,7 @@ export function createYomitanAnkiServerSyncRuntime(deps: YomitanAnkiServerSyncRu
|
||||
syncYomitanDefaultProfileAnkiServer: () => Promise<void>;
|
||||
} {
|
||||
let lastSyncedYomitanAnkiSettingsKey: string | null = null;
|
||||
const syncDefaultAnkiServer = deps.syncDefaultAnkiServer ?? syncYomitanDefaultAnkiServerCore;
|
||||
|
||||
function getPreferredYomitanAnkiServerUrl(): string {
|
||||
return getPreferredYomitanAnkiServerUrlRuntime(deps.getResolvedConfig().ankiConnect);
|
||||
@@ -50,7 +52,7 @@ export function createYomitanAnkiServerSyncRuntime(deps: YomitanAnkiServerSyncRu
|
||||
return;
|
||||
}
|
||||
|
||||
const synced = await syncYomitanDefaultAnkiServerCore(
|
||||
const synced = await syncDefaultAnkiServer(
|
||||
targetUrl,
|
||||
deps.getYomitanParserRuntimeDeps(),
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user