From 322b24671707c5dc73c51949731f6e5e28948553 Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Fri, 27 Apr 2012 12:30:58 -0500 Subject: Autogenerated Arbitrary instances for tests --- Makefile | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 2d9b719..105780e 100644 --- a/Makefile +++ b/Makefile @@ -19,9 +19,15 @@ debian: debian/control test: tests/suite tests/suite -tests/suite: tests/suite.hs Data/OpenPGP.hs Data/OpenPGP/Internal.hs +tests/suite: tests/suite.hs Data/OpenPGP.hs Data/OpenPGP/Internal.hs Data/OpenPGP/Arbitrary.hs ghc --make $(GHCFLAGS) -o $@ $^ +Data/OpenPGP/Arbitrary.hs: Data/OpenPGP.hs + derive -d Arbitrary -m Data.OpenPGP.Arbitrary -iData.OpenPGP -iTest.QuickCheck -iTest.QuickCheck.Instances -iNumeric -iData.Char -iData.Word -o $@ $^ + -printf ',s/SignaturePacket x1 x2 x3 x4 x5 x6 x7 x8 x9)$$/signaturePacket x1 x2 x3 x4 x5 x6 x7 x8)/g\n/signaturePacket/\n-d\nw\nq\n' | ed $@ + -printf '/return (IssuerPacket/\n-d\ni\n 4 -> do x1 <- fmap (map toUpper . (`showHex` "")) (arbitrary :: Gen Word64)\n.\nw\nq\n' | ed $@ + -printf '/return (UnsupportedSignatureSubpacket/\n-d\n.s/x1/105/g\n.s/x2/x1/g\nw\nq\n' | ed $@ + report.html: tests/suite.hs Data/OpenPGP.hs Data/OpenPGP/Internal.hs -hlint $(HLINTFLAGS) --report $^ -- cgit v1.2.3