@@ -25,11 +25,8 @@ import Encoders
25import Properties.Deprecated (deprecatedTests)
25import Properties.Deprecated (deprecatedTests)
26import System.IO
26import System.IO
27import System.IO.Unsafe (unsafePerformIO)
27import System.IO.Unsafe (unsafePerformIO)
30import Data.Int
28import Data.Int
31import qualified Data.Map as Map
29import qualified Data.Map as Map
34#if !MIN_VERSION_time(1,5,0)
31#if !MIN_VERSION_time(1,5,0)
35import System.Locale (defaultTimeLocale, dateTimeFmt)
32import System.Locale (defaultTimeLocale, dateTimeFmt)
@@ -153,10 +150,8 @@ main = do
153 comparisonTest <- encoderComparisonTests
150 comparisonTest <- encoderComparisonTests
154 defaultMain (comparisonTest : tests)
151 defaultMain (comparisonTest : tests)
157type P6 = Product6 Int Bool String (Approx Double) (Int, Approx Double) ()
153type P6 = Product6 Int Bool String (Approx Double) (Int, Approx Double) ()
158type S4 = Sum4 Int8 ZonedTime T.Text (Map.Map String Int)
154type S4 = Sum4 Int8 ZonedTime T.Text (Map.Map String Int)
161--------------------------------------------------------------------------------
156--------------------------------------------------------------------------------
162-- Value properties
157-- Value properties
@@ -207,14 +202,12 @@ tests = [
207 , testProperty "DotNetTime" $ roundTripEq (undefined :: DotNetTime)
202 , testProperty "DotNetTime" $ roundTripEq (undefined :: DotNetTime)
208 , testProperty "UTCTime" $ roundTripEq (undefined :: UTCTime)
203 , testProperty "UTCTime" $ roundTripEq (undefined :: UTCTime)
209 , testProperty "ZonedTime" $ roundTripEq (undefined :: ZonedTime)
204 , testProperty "ZonedTime" $ roundTripEq (undefined :: ZonedTime)
211 , testGroup "ghcGenerics" [
205 , testGroup "ghcGenerics" [
212 testProperty "OneConstructor" $ roundTripEq OneConstructor
206 testProperty "OneConstructor" $ roundTripEq OneConstructor
213 , testProperty "Product2" $ roundTripEq (undefined :: Product2 Int Bool)
207 , testProperty "Product2" $ roundTripEq (undefined :: Product2 Int Bool)
214 , testProperty "Product6" $ roundTripEq (undefined :: P6)
208 , testProperty "Product6" $ roundTripEq (undefined :: P6)
215 , testProperty "Sum4" $ roundTripEq (undefined :: S4)
209 , testProperty "Sum4" $ roundTripEq (undefined :: S4)
219 testGroup "toFromJSON" [
212 testGroup "toFromJSON" [
220 testProperty "Integer" (toFromJSON :: Integer -> Bool)
213 testProperty "Integer" (toFromJSON :: Integer -> Bool)
@@ -254,7 +247,6 @@ tests = [
258 , testGroup "GHC-generics" [
250 , testGroup "GHC-generics" [
259 testGroup "Nullary" [
251 testGroup "Nullary" [
260 testProperty "string" (isString . gNullaryToJSONString)
252 testProperty "string" (isString . gNullaryToJSONString)
@@ -291,7 +283,6 @@ tests = [