Skip to content

Commit 3a501df

Browse files
Gerdiejhatch28
authored andcommitted
patch tests and expand coverage for message
1 parent 8b33478 commit 3a501df

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

__tests__/message-spec.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ describe('Message', () => {
1515
testContext.connection = new NylasConnection('123', { clientId: 'foo' });
1616
testContext.message = new Message(testContext.connection);
1717
testContext.message.id = '4333';
18+
testContext.message.subject = 'foo';
19+
testContext.message.body = 'bar';
1820
testContext.message.starred = true;
1921
testContext.message.unread = false;
2022
testContext.message.to = [{"email": "foo", "name": "bar"}];
@@ -75,6 +77,8 @@ describe('Message', () => {
7577
test('should resolve with the message object', done => {
7678
testContext.message.save().then(message => {
7779
expect(message.id).toBe('4333');
80+
expect(message.body).toBe('bar');
81+
expect(message.subject).toBe('foo');
7882
let toParticipant = message.to[0];
7983
expect(toParticipant.toJSON()).toEqual(
8084
{'email': 'foo', 'name': 'bar'});

0 commit comments

Comments
 (0)