1
1
mirror of https://github.com/github/semantic.git synced 2024-12-24 23:42:31 +03:00

CategorySet is Categorizable.

This commit is contained in:
Rob Rix 2015-12-11 16:01:40 -05:00
parent 90b3da2291
commit 64c4787d81

View File

@ -1,5 +1,6 @@
module Main where
import Categorizable
import Diff
import Patch
import Range
@ -42,6 +43,12 @@ instance (Eq a, Eq annotation, Arbitrary a, Arbitrary annotation) => Arbitrary (
data CategorySet = A | B | C | D deriving (Eq, Show)
instance Categorizable CategorySet where
categories A = Set.fromList [ "a" ]
categories B = Set.fromList [ "b" ]
categories C = Set.fromList [ "c" ]
categories D = Set.fromList [ "d" ]
instance Arbitrary HTML where
arbitrary = oneof [
Text <$> arbitrary,