mirror of
https://github.com/keymanapp/keyman.git
synced 2026-09-11 10:07:42 +00:00
parent
2366653818
commit
554e66a4cd
5 changed files with 6 additions and 6 deletions
|
|
@ -26,8 +26,8 @@ export class LDMLKeyboardXMLSourceFileReader {
|
|||
constructor(private options: LDMLKeyboardXMLSourceFileReaderOptions, private callbacks : CompilerCallbacks) {
|
||||
}
|
||||
|
||||
static get defaultImportsURL() {
|
||||
return new URL(`../import/`, import.meta.url);
|
||||
static get defaultImportsURL(): [string,string] {
|
||||
return ['../import/', import.meta.url];
|
||||
}
|
||||
|
||||
readImportFile(version: string, subpath: string): Uint8Array {
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ import { TestCompilerCallbacks } from './TestCompilerCallbacks.js';
|
|||
import { fileURLToPath } from 'url';
|
||||
|
||||
const readerOptions: LDMLKeyboardXMLSourceFileReaderOptions = {
|
||||
importsPath: fileURLToPath(LDMLKeyboardXMLSourceFileReader.defaultImportsURL)
|
||||
importsPath: fileURLToPath(new URL(...LDMLKeyboardXMLSourceFileReader.defaultImportsURL))
|
||||
};
|
||||
|
||||
export interface CompilationCase {
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ export const compilerTestCallbacks = new TestCompilerCallbacks();
|
|||
|
||||
export const compilerTestOptions: LdmlCompilerOptions = {
|
||||
readerOptions: {
|
||||
importsPath: fileURLToPath(LDMLKeyboardXMLSourceFileReader.defaultImportsURL)
|
||||
importsPath: fileURLToPath(new URL(...LDMLKeyboardXMLSourceFileReader.defaultImportsURL))
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ async function buildLdmlKeyboardToMemory(inputFilename: string, callbacks: Compi
|
|||
...defaultCompilerOptions,
|
||||
...options,
|
||||
readerOptions: {
|
||||
importsPath: fileURLToPath(LDMLKeyboardXMLSourceFileReader.defaultImportsURL)
|
||||
importsPath: fileURLToPath(new URL(...LDMLKeyboardXMLSourceFileReader.defaultImportsURL))
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ export function buildTestData(infile: string, options: CompilerBaseOptions) {
|
|||
saveDebug: false,
|
||||
shouldAddCompilerVersion: false,
|
||||
readerOptions: {
|
||||
importsPath: fileURLToPath(LDMLKeyboardXMLSourceFileReader.defaultImportsURL)
|
||||
importsPath: fileURLToPath(new URL(...LDMLKeyboardXMLSourceFileReader.defaultImportsURL))
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue