mirror of
https://github.com/kevin-DL/sapper.git
synced 2026-01-13 11:35:28 +00:00
prevent unsafe replacements of preloaded data etc
This commit is contained in:
@@ -619,6 +619,16 @@ function run({ mode, basepath = '' }) {
|
||||
assert.equal(name, 'BODY');
|
||||
});
|
||||
});
|
||||
|
||||
it('replaces %sapper.xxx% tags safely', () => {
|
||||
return nightmare
|
||||
.goto(`${base}/unsafe-replacement`)
|
||||
.init()
|
||||
.page.html()
|
||||
.then(html => {
|
||||
assert.equal(html.indexOf('%sapper'), -1);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
describe('headers', () => {
|
||||
|
||||
Reference in New Issue
Block a user