Add tests for load costume error handling. Fix issue where asset data was not getting saved out properly.

This commit is contained in:
Karishma Chadha 2022-05-13 18:34:34 -04:00
parent a8618b378f
commit 70a78cf7db
15 changed files with 418 additions and 13 deletions
test/fixtures

View file

@ -12,5 +12,10 @@ module.exports = {
return JSON.parse(zip.readAsText(projectEntry.entryName, 'utf8'));
}
return null;
},
extractAsset: function (path, assetFileName) {
const zip = new AdmZip(path);
const assetEntry = zip.getEntries().filter(item => item.entryName.match(assetFileName))[0];
return assetEntry.getData();
}
};