Created
March 16, 2019 10:15
-
-
Save jasongorman/3186ddb600f946c3b93b6ead03079243 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const quote = require("../../src/tell_dont_ask/carpet_quote"); | |
const room = require("../../src/tell_dont_ask/room"); | |
const carpet = require("../../src/tell_dont_ask/carpet"); | |
test("quote for carpet without rounding up", () => { | |
expect(quote( | |
room(2.5, 2.5), | |
carpet(10.0, false)) | |
).toBe(62.5); | |
}) | |
test("quote for carpet with rounding up", () => { | |
expect(quote( | |
room(2.5, 2.5), | |
carpet(10.0, true)) | |
).toBe(70.0); | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment