Smart kettle

Smart kettle

Test report

Boil when the power is cheap › Ask for a cheap boil, lose the provider, get the boil not run

As a tea drinker, I want the kettle to boil when electricity is cheap, so that my morning cup costs less without me watching the price.

The test behind the tutorial Boil when the power is cheap: every step it takes, what it checks and what it saw.

Start

From the setup of Smart kettle.

Everything it starts with
Given the price feed is live
  And the cheap boil is off
No screenshot yet: the tests haven't run.
No screenshot yet: the tests haven't run.
  • the price feed is live · arranged
  • the cheap boil is off · arranged

1 When the user asks for a cheap boil

When the user asks for a cheap boil
Then the cheap boil is waiting

Expected behaviour: Asking for a cheap boil makes the kettle wait.

No screenshot yet: the tests haven't run.
No screenshot yet: the tests haven't run.

2 When the feed stops answering

When the feed stops answering
Then the price feed is unavailable
  And the cheap boil is waiting

Expected behaviour: A silent provider means no price.

No screenshot yet: the tests haven't run.
No screenshot yet: the tests haven't run.

3 When the feed answers again

When the feed answers again
Then the price feed is live

Expected behaviour: Retry brings the price back when the provider is back.

No screenshot yet: the tests haven't run.
No screenshot yet: the tests haven't run.

4 When the price drops to the cheap rate

When the price drops to the cheap rate
Then the cheap boil is boiling

Expected behaviour: A cheap price starts the boil.

No screenshot yet: the tests haven't run.
No screenshot yet: the tests haven't run.