Skip to content

Commit

Permalink
Add support for message type
Browse files Browse the repository at this point in the history
  • Loading branch information
jm-mailosaur committed Oct 12, 2022
1 parent 50c0601 commit 94d66cd
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/mailosaurCommands.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,10 @@ export interface Message {
* Unique identifier for the message.
*/
id?: string;
/**
* The type of message.
*/
type: 'Email' | 'SMS';
/**
* The sender of the message.
*/
Expand Down Expand Up @@ -220,6 +224,10 @@ export interface MessageSummary {
* Unique identifier for the message.
*/
id: string;
/**
* The type of message.
*/
type: 'Email' | 'SMS';
/**
* The sender of the message.
*/
Expand Down
1 change: 1 addition & 0 deletions test/react-app/cypress/e2e/messages.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ const validateHeaders = (email) => {
};

const validateMetadata = (email) => {
expect(email.type).to.equal('Email');
expect(email.from.length).to.equal(1);
expect(email.to.length).to.equal(1);
expect(email.from[0].email).to.be.ok;
Expand Down

0 comments on commit 94d66cd

Please sign in to comment.