Relax HTML checking in SingleFile tests
Somehow the saved page starts with "<html style>" instead of "<html>" on GitHub Actions
This commit is contained in:
parent
649d70eeda
commit
4c048f6fd2
1 changed files with 3 additions and 3 deletions
|
@ -362,7 +362,7 @@ describe("Zotero.Attachments", function() {
|
|||
let path = OS.Path.join(storageDir, 'index.html');
|
||||
assert.isTrue(await OS.File.exists(path));
|
||||
let contents = await Zotero.File.getContentsAsync(path);
|
||||
assert.isTrue(contents.startsWith("<html><!--\n Page saved with SingleFile"));
|
||||
assert.include(contents, "><!--\n Page saved with SingleFile");
|
||||
|
||||
// Check attachment base64 contents
|
||||
let expectedPath = getTestDataDirectory();
|
||||
|
@ -408,7 +408,7 @@ describe("Zotero.Attachments", function() {
|
|||
let path = OS.Path.join(storageDir, 'index.html');
|
||||
assert.isTrue(await OS.File.exists(path));
|
||||
let contents = await Zotero.File.getContentsAsync(path);
|
||||
assert.include(contents, "<html><!--\n Page saved with SingleFile");
|
||||
assert.include(contents, "><!--\n Page saved with SingleFile");
|
||||
|
||||
// Check attachment base64 contents
|
||||
let expectedPath = getTestDataDirectory();
|
||||
|
@ -460,7 +460,7 @@ describe("Zotero.Attachments", function() {
|
|||
let path = OS.Path.join(storageDir, 'index.html');
|
||||
assert.isTrue(await OS.File.exists(path));
|
||||
let contents = await Zotero.File.getContentsAsync(path);
|
||||
assert.include(contents, "<html><!--\n Page saved with SingleFile");
|
||||
assert.include(contents, "><!--\n Page saved with SingleFile");
|
||||
});
|
||||
|
||||
it("should save a document but not save the iframe", async function () {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue