Clarify test

This commit is contained in:
Sven van Heugten 2026-01-06 10:12:45 +01:00
parent 200e20c696
commit d4653bbc7f

View file

@ -103,10 +103,14 @@ type NightLightTests() =
let ``After a new day starts, all lights that have power should be on as long as the 'Off' button isn't pressed`` let ``After a new day starts, all lights that have power should be on as long as the 'Off' button isn't pressed``
() ()
= =
let genInitialTransitionToDay =
concatGens
[ Gen.bind genInteractionListThatStartsWithTimeChangedAndEndsWith genTimeChangedToNight
genInteractionListExcept isTimeChangedToDay
Gen.map List.singleton genTimeChangedToDay ]
concatGens concatGens
[ Gen.bind genInteractionListThatStartsWithTimeChangedAndEndsWith genTimeChangedToNight [ genInitialTransitionToDay
genInteractionListExcept isTimeChangedToDay
Gen.map List.singleton genTimeChangedToDay
genInteractionListExcept ((=) (HumanInteraction RemotePressedOffButton)) ] genInteractionListExcept ((=) (HumanInteraction RemotePressedOffButton)) ]
|> Arb.fromGen |> Arb.fromGen
|> Prop.forAll |> Prop.forAll