Skip to content

Instantly share code, notes, and snippets.

@daniellevass
Created February 3, 2020 19:28
Embed
What would you like to do?
spek medium post
describe("end to end flow of typical user") {
CurrentAccountImplementation.connect()
it("balance starts at 0") {
assertThat(CurrentAccountImplementation.getCurrentBalance()).isEqualTo(0)
}
it("balance is 10 when I add 10") {
CurrentAccountImplementation.addMoney(10)
assertThat(CurrentAccountImplementation.getCurrentBalance()).isEqualTo(10)
}
it("balance is 5 when I withdraw 5") {
CurrentAccountImplementation.takeMoney(5)
assertThat(CurrentAccountImplementation.getCurrentBalance()).isEqualTo(5)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment