We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fc79281 commit 23d3e7dCopy full SHA for 23d3e7d
src/__tests__/ParseFile-test.js
@@ -66,6 +66,12 @@ describe('ParseFile', () => {
66
expect(file._source.type).toBe('');
67
});
68
69
+ it('can create files with base64 encoding (no padding)', () => {
70
+ const file = new ParseFile('parse.txt', { base64: 'SGVsbG8gV29ybGQh' });
71
+ expect(file._source.base64).toBe('SGVsbG8gV29ybGQh');
72
+ expect(file._source.type).toBe('');
73
+ });
74
+
75
it('can set the default type to be text/plain when using base64', () => {
76
const file = new ParseFile('parse.txt', {
77
base64: 'data:;base64,ParseA==',
0 commit comments