fix: tests
This commit is contained in:
parent
af2d0d5185
commit
407e7c9f03
|
@ -18,6 +18,8 @@
|
|||
"files": [
|
||||
"index.js",
|
||||
"index.js.map",
|
||||
"test/fixtures/test.json",
|
||||
"test/fixtures/test2.json",
|
||||
"test.js",
|
||||
"test.js.map"
|
||||
],
|
||||
|
|
|
@ -33,7 +33,7 @@ describe('@avocado/resource', () => {
|
|||
describe('Resource', () => {
|
||||
it("can read resources", async () => {
|
||||
const buffer = await Resource.read('/test.json');
|
||||
expect(Buffer.compare(testJsonBuffer, buffer)).to.equal(0);
|
||||
expect(Buffer.compare(testJsonBuffer, Buffer.from(buffer))).to.equal(0);
|
||||
});
|
||||
it("generates unique uuids", async () => {
|
||||
const resources = [
|
||||
|
@ -46,7 +46,7 @@ describe('@avocado/resource', () => {
|
|||
});
|
||||
it("can be subclassed", async () => {
|
||||
const resource = await ResourceSubclass.load('/test.json');
|
||||
expect(Buffer.compare(testJsonBuffer, resource.buffer)).to.equal(0);
|
||||
expect(Buffer.compare(testJsonBuffer, Buffer.from(resource.buffer))).to.equal(0);
|
||||
});
|
||||
});
|
||||
describe('JsonResource', () => {
|
||||
|
|
Loading…
Reference in New Issue
Block a user