Add Attachment.removeSchemaVersion

This commit is contained in:
Daniel Gasienica 2018-03-13 21:27:28 -04:00
parent 37d35db3c3
commit 3dfc823716
2 changed files with 28 additions and 0 deletions

View file

@ -243,4 +243,26 @@ describe('Attachment', () => {
}
);
});
describe('removeSchemaVersion', () => {
it('should remove existing schema version', async () => {
const input = {
contentType: 'image/jpeg',
data: null,
fileName: 'foo.jpg',
size: 1111,
schemaVersion: 1,
};
const expected = {
contentType: 'image/jpeg',
data: null,
fileName: 'foo.jpg',
size: 1111,
};
const actual = await Attachment.removeSchemaVersion(input);
assert.deepEqual(actual, expected);
});
});
});