refactor: migrate legacy wire namespace to wrn
This commit is contained in:
@@ -3,7 +3,7 @@ import { mkdtempSync, mkdirSync, readFileSync, rmSync, writeFileSync } from "nod
|
||||
import { tmpdir } from "node:os";
|
||||
import { join } from "node:path";
|
||||
import {
|
||||
compileWireArtifactsAsync,
|
||||
compileWrnArtifactsAsync,
|
||||
setCompileCacheDir,
|
||||
setCompileImportOptions,
|
||||
} from "../src/pipeline.ts";
|
||||
@@ -27,7 +27,7 @@ page Settings {
|
||||
|
||||
try {
|
||||
setCompileCacheDir(cache);
|
||||
const artifacts = await compileWireArtifactsAsync(page);
|
||||
const artifacts = await compileWrnArtifactsAsync(page);
|
||||
const browser = readFileSync(artifacts.browser, "utf8");
|
||||
expect(browser).toContain("wrnexus-client-bundled");
|
||||
expect(browser).not.toContain("file://");
|
||||
@@ -65,7 +65,7 @@ page Settings {
|
||||
aliases: { "~": "./app" },
|
||||
autoImport: false,
|
||||
});
|
||||
const artifacts = await compileWireArtifactsAsync(page);
|
||||
const artifacts = await compileWrnArtifactsAsync(page);
|
||||
const browser = readFileSync(artifacts.browser, "utf8");
|
||||
expect(browser).toContain("wrnexus-client-bundled");
|
||||
expect(browser).not.toContain("~/client/storage.ts");
|
||||
@@ -81,7 +81,7 @@ page Settings {
|
||||
aliases: { "~": "./alternate" },
|
||||
autoImport: false,
|
||||
});
|
||||
const changed = await compileWireArtifactsAsync(page);
|
||||
const changed = await compileWrnArtifactsAsync(page);
|
||||
expect(changed.browser).not.toBe(artifacts.browser);
|
||||
} finally {
|
||||
setCompileCacheDir(null);
|
||||
|
||||
Reference in New Issue
Block a user