| 1 |
--- a/sandi.cabal |
| 2 |
+++ b/sandi.cabal |
| 3 |
@@ -93,7 +93,6 @@ |
| 4 |
, tasty |
| 5 |
, tasty-hunit |
| 6 |
, tasty-quickcheck |
| 7 |
- , tasty-th |
| 8 |
default-language: Haskell2010 |
| 9 |
|
| 10 |
benchmark sandi-bench |
| 11 |
--- a/test-src/Codec/Binary/Base16Test.hs |
| 12 |
+++ b/test-src/Codec/Binary/Base16Test.hs |
| 13 |
@@ -1,4 +1,3 @@ |
| 14 |
-{-# LANGUAGE TemplateHaskell #-} |
| 15 |
-- Copyright: (c) Magnus Therning, 2013 |
| 16 |
-- License: BSD3, found in the LICENSE file |
| 17 |
|
| 18 |
@@ -12,7 +11,6 @@ |
| 19 |
import Data.Word (Word8) |
| 20 |
|
| 21 |
import Test.Tasty |
| 22 |
-import Test.Tasty.TH |
| 23 |
import Test.Tasty.HUnit |
| 24 |
import Test.Tasty.QuickCheck |
| 25 |
|
| 26 |
@@ -45,4 +43,9 @@ |
| 27 |
prop_b16_encdec ws = BS.pack ws == fromRight (B16.decode $ B16.encode $ BS.pack ws) |
| 28 |
|
| 29 |
tests :: TestTree |
| 30 |
-tests = $(testGroupGenerator) |
| 31 |
+tests = testGroup |
| 32 |
+ "Codec.Binary.Base16Test" |
| 33 |
+ [testProperty "b16 encdec" prop_b16_encdec, |
| 34 |
+ testCase "b16 enc foobar" case_b16_enc_foobar, |
| 35 |
+ testCase "b16 dec foobar" case_b16_dec_foobar, |
| 36 |
+ testCase "b16 dec failure" case_b16_dec_failure] |
| 37 |
--- a/test-src/Codec/Binary/Base32HexTest.hs |
| 38 |
+++ b/test-src/Codec/Binary/Base32HexTest.hs |
| 39 |
@@ -1,4 +1,3 @@ |
| 40 |
-{-# LANGUAGE TemplateHaskell #-} |
| 41 |
-- Copyright: (c) Magnus Therning, 2013 |
| 42 |
-- License: BSD3, found in the LICENSE file |
| 43 |
|
| 44 |
@@ -12,7 +11,6 @@ |
| 45 |
import Data.Word (Word8) |
| 46 |
|
| 47 |
import Test.Tasty |
| 48 |
-import Test.Tasty.TH |
| 49 |
import Test.Tasty.HUnit |
| 50 |
import Test.Tasty.QuickCheck |
| 51 |
|
| 52 |
@@ -49,4 +47,9 @@ |
| 53 |
prop_encdec ws = BS.pack ws == fromRight (B32H.decode $ B32H.encode $ BS.pack ws) |
| 54 |
|
| 55 |
tests :: TestTree |
| 56 |
-tests = $(testGroupGenerator) |
| 57 |
+tests = testGroup |
| 58 |
+ "Codec.Binary.Base32HexTest" |
| 59 |
+ [testProperty "encdec" prop_encdec, |
| 60 |
+ testCase "enc foobar" case_enc_foobar, |
| 61 |
+ testCase "dec foobar" case_dec_foobar, |
| 62 |
+ testCase "dec failures" case_dec_failures] |
| 63 |
--- a/test-src/Codec/Binary/Base32Test.hs |
| 64 |
+++ b/test-src/Codec/Binary/Base32Test.hs |
| 65 |
@@ -1,4 +1,3 @@ |
| 66 |
-{-# LANGUAGE TemplateHaskell #-} |
| 67 |
-- Copyright: (c) Magnus Therning, 2013 |
| 68 |
-- License: BSD3, found in the LICENSE file |
| 69 |
|
| 70 |
@@ -12,7 +11,6 @@ |
| 71 |
import Data.Word (Word8) |
| 72 |
|
| 73 |
import Test.Tasty |
| 74 |
-import Test.Tasty.TH |
| 75 |
import Test.Tasty.HUnit |
| 76 |
import Test.Tasty.QuickCheck |
| 77 |
|
| 78 |
@@ -49,4 +47,9 @@ |
| 79 |
prop_encdec ws = BS.pack ws == fromRight (B32.decode $ B32.encode $ BS.pack ws) |
| 80 |
|
| 81 |
tests :: TestTree |
| 82 |
-tests = $(testGroupGenerator) |
| 83 |
+tests = testGroup |
| 84 |
+ "Codec.Binary.Base32Test" |
| 85 |
+ [testProperty "encdec" prop_encdec, |
| 86 |
+ testCase "enc foobar" case_enc_foobar, |
| 87 |
+ testCase "dec foobar" case_dec_foobar, |
| 88 |
+ testCase "dec failures" case_dec_failures] |
| 89 |
--- a/test-src/Codec/Binary/Base64Test.hs |
| 90 |
+++ b/test-src/Codec/Binary/Base64Test.hs |
| 91 |
@@ -1,4 +1,3 @@ |
| 92 |
-{-# LANGUAGE TemplateHaskell #-} |
| 93 |
-- Copyright: (c) Magnus Therning, 2013 |
| 94 |
-- License: BSD3, found in the LICENSE file |
| 95 |
|
| 96 |
@@ -12,7 +11,6 @@ |
| 97 |
import Data.Word (Word8) |
| 98 |
|
| 99 |
import Test.Tasty |
| 100 |
-import Test.Tasty.TH |
| 101 |
import Test.Tasty.HUnit |
| 102 |
import Test.Tasty.QuickCheck |
| 103 |
|
| 104 |
@@ -50,4 +48,10 @@ |
| 105 |
prop_encdec ws = BS.pack ws == fromRight (B64.decode $ B64.encode $ BS.pack ws) |
| 106 |
|
| 107 |
tests :: TestTree |
| 108 |
-tests = $(testGroupGenerator) |
| 109 |
+tests = testGroup |
| 110 |
+ "Codec.Binary.Base64Test" |
| 111 |
+ [testProperty "encdec" prop_encdec, |
| 112 |
+ testCase "enc foobar" case_enc_foobar, |
| 113 |
+ testCase "enc specials" case_enc_specials, |
| 114 |
+ testCase "dec foobar" case_dec_foobar, |
| 115 |
+ testCase "dec specials" case_dec_specials] |
| 116 |
--- a/test-src/Codec/Binary/Base64UrlTest.hs |
| 117 |
+++ b/test-src/Codec/Binary/Base64UrlTest.hs |
| 118 |
@@ -1,4 +1,3 @@ |
| 119 |
-{-# LANGUAGE TemplateHaskell #-} |
| 120 |
-- Copyright: (c) Magnus Therning, 2013 |
| 121 |
-- License: BSD3, found in the LICENSE file |
| 122 |
|
| 123 |
@@ -12,7 +11,6 @@ |
| 124 |
import Data.Word (Word8) |
| 125 |
|
| 126 |
import Test.Tasty |
| 127 |
-import Test.Tasty.TH |
| 128 |
import Test.Tasty.HUnit |
| 129 |
import Test.Tasty.QuickCheck |
| 130 |
|
| 131 |
@@ -50,4 +48,10 @@ |
| 132 |
prop_encdec ws = BS.pack ws == fromRight (B64U.decode $ B64U.encode $ BS.pack ws) |
| 133 |
|
| 134 |
tests :: TestTree |
| 135 |
-tests = $(testGroupGenerator) |
| 136 |
+tests = testGroup |
| 137 |
+ "Codec.Binary.Base64UrlTest" |
| 138 |
+ [testProperty "encdec" prop_encdec, |
| 139 |
+ testCase "enc foobar" case_enc_foobar, |
| 140 |
+ testCase "enc specials" case_enc_specials, |
| 141 |
+ testCase "dec foobar" case_dec_foobar, |
| 142 |
+ testCase "dec specials" case_dec_specials] |
| 143 |
--- a/test-src/Codec/Binary/Base85Test.hs |
| 144 |
+++ b/test-src/Codec/Binary/Base85Test.hs |
| 145 |
@@ -1,4 +1,3 @@ |
| 146 |
-{-# LANGUAGE TemplateHaskell #-} |
| 147 |
-- Copyright: (c) Magnus Therning, 2013 |
| 148 |
-- License: BSD3, found in the LICENSE file |
| 149 |
|
| 150 |
@@ -12,7 +11,6 @@ |
| 151 |
import Data.Word (Word8) |
| 152 |
|
| 153 |
import Test.Tasty |
| 154 |
-import Test.Tasty.TH |
| 155 |
import Test.Tasty.HUnit |
| 156 |
import Test.Tasty.QuickCheck |
| 157 |
|
| 158 |
@@ -59,4 +57,10 @@ |
| 159 |
prop_encdec ws = BS.pack ws == fromRight (B85.decode $ B85.encode $ BS.pack ws) |
| 160 |
|
| 161 |
tests :: TestTree |
| 162 |
-tests = $(testGroupGenerator) |
| 163 |
+tests = testGroup |
| 164 |
+ "Codec.Binary.Base85Test" |
| 165 |
+ [testProperty "encdec" prop_encdec, |
| 166 |
+ testCase "enc foobar" case_enc_foobar, |
| 167 |
+ testCase "enc specials" case_enc_specials, |
| 168 |
+ testCase "dec foobar" case_dec_foobar, |
| 169 |
+ testCase "dec specials" case_dec_specials] |
| 170 |
--- a/test-src/Codec/Binary/QuotedPrintableTest.hs |
| 171 |
+++ b/test-src/Codec/Binary/QuotedPrintableTest.hs |
| 172 |
@@ -1,4 +1,3 @@ |
| 173 |
-{-# LANGUAGE TemplateHaskell #-} |
| 174 |
-- Copyright: (c) Magnus Therning, 2013-2015 |
| 175 |
-- License: BSD3, found in the LICENSE file |
| 176 |
|
| 177 |
@@ -12,7 +11,6 @@ |
| 178 |
import Data.Word (Word8) |
| 179 |
|
| 180 |
import Test.Tasty |
| 181 |
-import Test.Tasty.TH |
| 182 |
import Test.Tasty.HUnit |
| 183 |
import Test.Tasty.QuickCheck |
| 184 |
|
| 185 |
@@ -48,4 +46,9 @@ |
| 186 |
prop_encdec ws = BS.pack ws == fromRight (QP.decode $ QP.encode $ BS.pack ws) |
| 187 |
|
| 188 |
tests :: TestTree |
| 189 |
-tests = $(testGroupGenerator) |
| 190 |
+tests = testGroup |
| 191 |
+ "Codec.Binary.QuotedPrintableTest" |
| 192 |
+ [testProperty "encdec" prop_encdec, |
| 193 |
+ testCase "enc foobar" case_enc_foobar, |
| 194 |
+ testCase "enc splitting" case_enc_splitting, |
| 195 |
+ testCase "dec foobar" case_dec_foobar] |
| 196 |
--- a/test-src/Codec/Binary/UuTest.hs |
| 197 |
+++ b/test-src/Codec/Binary/UuTest.hs |
| 198 |
@@ -1,4 +1,3 @@ |
| 199 |
-{-# LANGUAGE TemplateHaskell #-} |
| 200 |
-- Copyright: (c) Magnus Therning, 2013 |
| 201 |
-- License: BSD3, found in the LICENSE file |
| 202 |
|
| 203 |
@@ -12,7 +11,6 @@ |
| 204 |
import Data.Word (Word8) |
| 205 |
|
| 206 |
import Test.Tasty |
| 207 |
-import Test.Tasty.TH |
| 208 |
import Test.Tasty.HUnit |
| 209 |
import Test.Tasty.QuickCheck |
| 210 |
|
| 211 |
@@ -40,4 +38,8 @@ |
| 212 |
prop_encdec ws = BS.pack ws == fromRight (Uu.decode $ Uu.encode $ BS.pack ws) |
| 213 |
|
| 214 |
tests :: TestTree |
| 215 |
-tests = $(testGroupGenerator) |
| 216 |
+tests = testGroup |
| 217 |
+ "Codec.Binary.UuTest" |
| 218 |
+ [testProperty "encdec" prop_encdec, |
| 219 |
+ testCase "enc foobar" case_enc_foobar, |
| 220 |
+ testCase "dec foobar" case_dec_foobar] |
| 221 |
--- a/test-src/Codec/Binary/XxTest.hs |
| 222 |
+++ b/test-src/Codec/Binary/XxTest.hs |
| 223 |
@@ -1,4 +1,3 @@ |
| 224 |
-{-# LANGUAGE TemplateHaskell #-} |
| 225 |
-- Copyright: (c) Magnus Therning, 2013 |
| 226 |
-- License: BSD3, found in the LICENSE file |
| 227 |
|
| 228 |
@@ -12,7 +11,6 @@ |
| 229 |
import Data.Word (Word8) |
| 230 |
|
| 231 |
import Test.Tasty |
| 232 |
-import Test.Tasty.TH |
| 233 |
import Test.Tasty.HUnit |
| 234 |
import Test.Tasty.QuickCheck |
| 235 |
|
| 236 |
@@ -40,4 +38,8 @@ |
| 237 |
prop_encdec ws = BS.pack ws == fromRight (Xx.decode $ Xx.encode $ BS.pack ws) |
| 238 |
|
| 239 |
tests :: TestTree |
| 240 |
-tests = $(testGroupGenerator) |
| 241 |
+tests = testGroup |
| 242 |
+ "Codec.Binary.XxTest" |
| 243 |
+ [testProperty "encdec" prop_encdec, |
| 244 |
+ testCase "enc foobar" case_enc_foobar, |
| 245 |
+ testCase "dec foobar" case_dec_foobar] |
| 246 |
--- a/test-src/Codec/Binary/YencTest.hs |
| 247 |
+++ b/test-src/Codec/Binary/YencTest.hs |
| 248 |
@@ -1,4 +1,3 @@ |
| 249 |
-{-# LANGUAGE TemplateHaskell #-} |
| 250 |
-- Copyright: (c) Magnus Therning, 2013 |
| 251 |
-- License: BSD3, found in the LICENSE file |
| 252 |
|
| 253 |
@@ -12,7 +11,6 @@ |
| 254 |
import Data.Word (Word8) |
| 255 |
|
| 256 |
import Test.Tasty |
| 257 |
-import Test.Tasty.TH |
| 258 |
import Test.Tasty.QuickCheck |
| 259 |
import Test.Tasty.HUnit |
| 260 |
|
| 261 |
@@ -56,4 +54,10 @@ |
| 262 |
prop_encdec ws = BS.pack ws == fromRight (Y.decode $ Y.encode $ BS.pack ws) |
| 263 |
|
| 264 |
tests :: TestTree |
| 265 |
-tests = $(testGroupGenerator) |
| 266 |
+tests = testGroup |
| 267 |
+ "Codec.Binary.YencTest" |
| 268 |
+ [testProperty "encdec" prop_encdec, |
| 269 |
+ testCase "enc foobar" case_enc_foobar, |
| 270 |
+ testCase "enc specials" case_enc_specials, |
| 271 |
+ testCase "dec foobar" case_dec_foobar, |
| 272 |
+ testCase "dec specials" case_dec_specials] |