about summary refs log blame commit diff
path: root/src/Xanthous/Entities/Arbitrary.hs
blob: 9153722d9b12c4634ac75d934341ba30a8ee0a98 (plain) (tree)


















                                                                                
{-# OPTIONS_GHC -fno-warn-orphans #-}
--------------------------------------------------------------------------------
module Xanthous.Entities.Arbitrary () where
--------------------------------------------------------------------------------
import           Xanthous.Prelude
--------------------------------------------------------------------------------
import           Test.QuickCheck
import qualified Test.QuickCheck.Gen as Gen
--------------------------------------------------------------------------------
import           Xanthous.Entities (SomeEntity(..))
import           Xanthous.Entities.Character
import           Xanthous.Entities.Environment
--------------------------------------------------------------------------------

instance Arbitrary SomeEntity where
  arbitrary = Gen.oneof
    [ pure $ SomeEntity Character
    , pure $ SomeEntity Wall
    ]