Skip to content

Commit

Permalink
Fixed disabled VFS tests (#185)
Browse files Browse the repository at this point in the history
Fixes VFS tests that were commented out due to assertion issues relating to null byte characters not visible in console output, hence not caught.
  • Loading branch information
ajmeese7 authored Jul 31, 2022
1 parent 888b8b9 commit 6a8fe4d
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions __tests__/utils/vfs.js
Original file line number Diff line number Diff line change
Expand Up @@ -194,11 +194,10 @@ describe('utils.vfs#transformArrayBuffer', () => {
const testAbString = ab2str(testAb);
const create = type => vfs.transformArrayBuffer(testAb, 'text/plain', type);

/* FIXME
test('Should create string', () =>
create('string')
.then(result => expect(result).toBe('foo')));
*/
.then(result => result.replace(/\0/g, ''))
.then(result => expect(result).toBe(testText)));

test('Should create data url', async () => {
const result = await create('uri');
Expand All @@ -210,12 +209,11 @@ describe('utils.vfs#transformArrayBuffer', () => {
expect(index).not.toBe(-1);
});

/* FIXME
test('Should create blob', () =>
create('blob')
.then(blob2str)
.then(result => result.replace(/\0/g, ''))
.then(result => expect(result).toBe(testText)));
*/

test('Should create arraybuffer (default)', () =>
create('arraybuffer')
Expand Down

0 comments on commit 6a8fe4d

Please sign in to comment.