mirror of
https://github.com/github/semantic.git
synced 2024-11-28 10:15:55 +03:00
Ensure that we can shrink when either childContents or childMargin is empty.
This commit is contained in:
parent
21fac60bf1
commit
0e86c8149a
@ -195,7 +195,7 @@ instance Arbitrary Child where
|
||||
padding char = frequency [ (10, pure char)
|
||||
, (1, pure '\n') ]
|
||||
|
||||
shrink Child {..} = Child childKey <$> shrinkList (const []) childContents <*> shrinkList (const []) childMargin
|
||||
shrink Child {..} = Child childKey <$> "" : shrinkList (const []) childContents <*> "" : shrinkList (const []) childMargin
|
||||
|
||||
instance Show Child where
|
||||
show Child {..} = childMargin ++ "(" ++ childKey ++ childContents ++ ")"
|
||||
|
Loading…
Reference in New Issue
Block a user