{-# LANGUAGE TemplateHaskell, OverloadedStrings #-} {-# OPTIONS_GHC -Wno-orphans #-} {-| Module: TestSTMHub Description: Test reading lines from text files. Copyright: © 2017 All rights reserved. License: GPL-3 Maintainer: Evan Cofsky Stability: experimental Portability: POSIX -} module TestSTMHub where import Lawless import Text hiding (text) import STM import Arbitrary() import Test.Framework import Test.Framework.TH import Test.Framework.Providers.QuickCheck2 (testProperty) import Test.QuickCheck import Test.QuickCheck.Monadic import Line default (Text) prop_CheckSingle ∷ [Line] → Property prop_CheckSingle lns = monadicIO $ do m ← run $ readWriteLines lns assert (lns == m) properties ∷ Test properties = $(testGroupGenerator)