Smart kettle

Smart kettle

Seeing the electricity price

The smart kettle is for people who want to spend less on hot drinks, such as someone who makes tea every morning and would rather boil when power is cheap. They open the app and read the price. They use it to decide whether to boil now or wait.

The price comes from an outside provider (Price provider). The kettle shows what the provider sends and does not work out prices by itself. Next to the price, a dot says how much to trust it. Green means the price is current. Amber means the provider is late, so the price is old: the app says when it was last updated, and you should treat the price as a guide only.

If the provider does not answer, the app has no current price to show. It says so and does not show an old price as if it were new. When the provider is back, tap Retry to get the price again.

A late provider is shown as delayed

The amber dot means the price is old. The app shows when it was last updated, so you can judge it.

If the price feed is live, make the test provider send prices late. The price has an amber dot and says when it was last updated.

Screenshot to come.
Screenshot to come.

See it in Knowing how far to trust the price.

How this is tested not run
Given the price feed is live
When the feed falls behind
Then the price feed is delayed
Follows
the section's setup
Leads to
A delayed feed can stop answering
Tested by
Knowing how far to trust the price › A price goes late, then missing, then returns not run

A silent provider means no price

The app says "Prices unavailable" and shows no number. A price that might be hours old is worse than none.

If the price feed is live, switch the test provider off. The price is replaced by the message "Prices unavailable" and a Retry button.

Screenshot to come.
Screenshot to come.

See it in Boil when the power is cheap.

How this is tested not run
Given the price feed is live
When the feed stops answering
Then the price feed is unavailable
Follows
the section's setup
Leads to
Without a price the kettle keeps waiting, Retry brings the price back when the provider is back
Tested by
Boil when the power is cheap › Ask for a cheap boil, lose the provider, get the boil not run

A delayed feed can stop answering

If the price feed is delayed, switch the test provider off. The price is replaced by the message "Prices unavailable" and a Retry button.

Screenshot to come.
Screenshot to come.

See it in Knowing how far to trust the price.

How this is tested not run
Given the price feed is delayed
When the feed stops answering
Then the price feed is unavailable
Follows
A late provider is shown as delayed
Tested by
Knowing how far to trust the price › A price goes late, then missing, then returns not run

Retry brings the price back when the provider is back

If the price feed is unavailable, switch the test provider back on and tap Retry. The price has a green dot.

Screenshot to come.
Screenshot to come.

See it in Boil when the power is cheap, Knowing how far to trust the price.

How this is tested not run
Given the price feed is unavailable
When the feed answers again
Then the price feed is live
Follows
A silent provider means no price
Tested by
Boil when the power is cheap › Ask for a cheap boil, lose the provider, get the boil not run, Knowing how far to trust the price › A price goes late, then missing, then returns not run