Implement the 'Left' button on the remote
This commit is contained in:
parent
6ecb6d07ac
commit
2950b21488
7 changed files with 91 additions and 19 deletions
|
|
@ -9,10 +9,31 @@ type ArbitraryLight =
|
|||
type ArbitraryNonRemotelyControlledLight =
|
||||
static member Light() =
|
||||
lights
|
||||
|> Seq.filter (not << _.ControlledWithRemote)
|
||||
|> Seq.filter _.ControlledWithRemote.IsNonRemote
|
||||
|> Gen.elements
|
||||
|> Arb.fromGen
|
||||
|
||||
type ArbitraryLeftRemotelyControlledLight =
|
||||
static member Light() =
|
||||
lights
|
||||
|> Seq.filter _.ControlledWithRemote.IsRemoteLeft
|
||||
|> Gen.elements
|
||||
|> Arb.fromGen
|
||||
|
||||
type ArbitraryRightRemotelyControlledLight =
|
||||
static member Light() =
|
||||
lights
|
||||
|> Seq.filter _.ControlledWithRemote.IsRemoteRight
|
||||
|> Gen.elements
|
||||
|> Arb.fromGen
|
||||
|
||||
type ArbitraryRemotelyControlledLight =
|
||||
static member Light() =
|
||||
lights |> Seq.filter _.ControlledWithRemote |> Gen.elements |> Arb.fromGen
|
||||
lights
|
||||
|> Seq.filter (fun light ->
|
||||
match light.ControlledWithRemote with
|
||||
| RemoteLeft -> true
|
||||
| RemoteRight -> true
|
||||
| NonRemote -> false)
|
||||
|> Gen.elements
|
||||
|> Arb.fromGen
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue