Cache the page-owned app response before starting the worker
This commit is contained in:
@@ -30,7 +30,7 @@ test('Phase 4 preserves the exact player, continuity, tracking and queue bodies'
|
||||
test('eager shell and Settings definitions load before app state and defer reading it',()=>{
|
||||
const html=readFileSync(join(__dirname,'index.html'),'utf8');
|
||||
for(const file of ['shell-core.js','views-core.js','section-rail.js']) {
|
||||
assert.ok(html.indexOf('src="'+file+'"')<html.indexOf('src="app.js"'));
|
||||
assert.ok(html.indexOf('src="'+file+'"')<html.indexOf('src="app-bootstrap.js"'));
|
||||
const vm=require('node:vm');const context=vm.createContext({window:{},document:{}});
|
||||
// Evaluation before any data/$/els/Player declaration must be safe.
|
||||
vm.runInContext(readFileSync(join(__dirname,file),'utf8'),context);
|
||||
|
||||
Reference in New Issue
Block a user