Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions exercises/concept/factory-sensors/factory-sensors.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,18 @@ import {
} from './factory-sensors';

describe('checkHumidityLevel', () => {
test('should throw if the humidity percentage is 71', () => {
expect(() => checkHumidityLevel(71)).toThrow();
});

test('should throw if the humidity percentage is 100', () => {
expect(() => checkHumidityLevel(100)).toThrow();
});

test('should not throw if the humidity level is 70', () => {
expect(() => checkHumidityLevel(70)).not.toThrow();
});

test('should not throw if the humidity level is 53', () => {
expect(() => checkHumidityLevel(53)).not.toThrow();
});
Expand Down