Skip to content

Commit

Permalink
streamsReducer tests: Remove test for nonexistent email_address pro…
Browse files Browse the repository at this point in the history
…perty

This isn't a valid property of a stream, according to our Flow
types. Flow would normally complain, except that this is one of the
few files that doesn't have type-checking yet. We'll fix that next.
  • Loading branch information
chrisbobbe committed Apr 14, 2022
1 parent 5e6d5b5 commit 6716c79
Showing 1 changed file with 0 additions and 56 deletions.
56 changes: 0 additions & 56 deletions src/streams/__tests__/streamsReducer-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -308,61 +308,5 @@ describe('streamsReducer', () => {

expect(actualState).toEqual(expectedState);
});

test('Change the email_address property', () => {
const initialState = deepFreeze([
{
stream_id: 123,
name: 'competition',
email_address: '123@realm.com',
},
{
stream_id: 67,
name: 'design',
email_address: '67@realm.com',
},
{
stream_id: 53,
name: 'mobile',
email_address: '53@realm.com',
},
]);

const action = deepFreeze({
type: EVENT,
event: {
type: EventTypes.stream,
stream_id: 123,
op: 'update',
eventId: 2,
id: 2,
name: 'competition',
property: 'email_address',
value: '1234@realm.com',
},
});

const expectedState = [
{
stream_id: 123,
name: 'competition',
email_address: '1234@realm.com',
},
{
stream_id: 67,
name: 'design',
email_address: '67@realm.com',
},
{
stream_id: 53,
name: 'mobile',
email_address: '53@realm.com',
},
];

const actualState = streamsReducer(initialState, action);

expect(actualState).toEqual(expectedState);
});
});
});

0 comments on commit 6716c79

Please sign in to comment.