From 59baf88294c0de24af03bb8b681703a09a91d6d6 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Wed, 27 Mar 2019 00:47:50 +0100 Subject: [PATCH] Test instances for LecturerType --- test/Model/TypesSpec.hs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/test/Model/TypesSpec.hs b/test/Model/TypesSpec.hs index bfe154a02..d30237550 100644 --- a/test/Model/TypesSpec.hs +++ b/test/Model/TypesSpec.hs @@ -140,6 +140,10 @@ instance Arbitrary AuthenticationMode where shrink AuthLDAP = [] shrink (AuthPWHash _) = [AuthLDAP] + +instance Arbitrary LecturerType where + arbitrary = genericArbitrary + shrink = genericShrink spec :: Spec @@ -199,6 +203,8 @@ spec = do [ eqLaws, ordLaws, showReadLaws, boundedEnumLaws, finiteLaws, hashableLaws, jsonLaws, pathPieceLaws, jsonKeyLaws ] lawsCheckHspec (Proxy @AuthTagActive) [ eqLaws, ordLaws, showReadLaws, jsonLaws, persistFieldLaws ] + lawsCheckHspec (Proxy @LecturerType) + [ eqLaws, ordLaws, showReadLaws, boundedEnumLaws, finiteLaws, jsonLaws, pathPieceLaws, persistFieldLaws ] describe "TermIdentifier" $ do it "has compatible encoding/decoding to/from Text" . property $