chore: update dependencies to rollup 4 and remove unneeded dependencies
This commit is contained in:
@@ -8,18 +8,10 @@ import {writeFile} from "node:fs/promises";
|
||||
|
||||
import html from "../../src/index.ts";
|
||||
|
||||
const output = {
|
||||
dir: 'output', // Output all files
|
||||
format: 'es', // iifi and cjs should be added to tests
|
||||
sourcemap: true,// Test if #sourcemapUrl is not accidentally included in the html-output
|
||||
// Prevent hashes from being added (and screw up the snapshots)
|
||||
chunkFileNames: '[name].js',
|
||||
entryFileNames: '[name].[extname]',
|
||||
assetFileNames: '[name].[extname]',
|
||||
};
|
||||
|
||||
import {fileURLToPath} from "node:url";
|
||||
import {pathToFileURL} from "url";
|
||||
import {defaultOutput} from "../util/default-output.ts";
|
||||
const __dirname = dirname(fileURLToPath(import.meta.url));
|
||||
process.chdir(join(__dirname, 'fixtures'));
|
||||
|
||||
@@ -35,9 +27,10 @@ test('watch', async () => {
|
||||
const path = resolve(__dirname, 'fixtures/watched-file.js');
|
||||
await writeFile(path, origContent, {encoding: 'utf-8'});
|
||||
|
||||
const output = defaultOutput;
|
||||
const watcher = rollup.watch({
|
||||
input: 'index.html',
|
||||
output,
|
||||
output: output,
|
||||
plugins: [
|
||||
html({
|
||||
}),
|
||||
@@ -53,7 +46,7 @@ test('watch', async () => {
|
||||
// Just wait on the watch mode to pick up on the changes
|
||||
},
|
||||
async (bundle)=>{
|
||||
const code = await getCode(bundle, output);
|
||||
const code = await getCode(bundle);
|
||||
debugPrintOutput('watch',code);
|
||||
|
||||
// Reset the source file
|
||||
|
||||
Reference in New Issue
Block a user