packages feed

atom-conduit 0.5.0.0 → 0.5.0.1

raw patch · 5 files changed

+35/−17 lines, 5 filesdep ~basePVP ok

version bump matches the API change (PVP)

Dependency ranges changed: base

API changes (from Hackage documentation)

Files

Text/Atom/Conduit/Parse.hs view
@@ -30,7 +30,7 @@  import           Control.Applicative      hiding (many) import           Control.Exception.Safe   as Exception-import           Control.Monad            hiding (foldM)+import           Control.Monad import           Control.Monad.Fix  import           Data.Conduit@@ -47,7 +47,7 @@  import           Lens.Simple -import           Prelude                  hiding (last, lookup)+import           Prelude  import           Text.Atom.Types import           Text.XML.Stream.Parse@@ -58,7 +58,7 @@  -- {{{ Util data AtomException = InvalidDate Text-                   | InvalidURI URIParseError+                   | InvalidURI URIParseError Text                    | MissingElement Text                    | NullElement @@ -66,16 +66,16 @@ deriving instance Show AtomException  instance Exception AtomException where-  displayException (InvalidDate t)    = "Invalid date: " ++ unpack t-  displayException (InvalidURI e)     = "Invalid URI reference: " ++ show e-  displayException (MissingElement t) = "Missing element: " ++ unpack t+  displayException (InvalidDate t)    = "Invalid date: " <> unpack t+  displayException (InvalidURI e t)   = "Invalid URI reference: " <> show e <> " in " <> unpack t+  displayException (MissingElement t) = "Missing element: " <> unpack t   displayException NullElement        = "Null element"  asURIReference :: MonadThrow m => Text -> m AtomURI asURIReference t = case (parseURI' t, parseRelativeRef' t) of   (Right u, _)     -> return $ AtomURI u   (_, Right u)     -> return $ AtomURI u-  (Left _, Left e) -> throwM $ InvalidURI e+  (Left _, Left e) -> throwM $ InvalidURI e t   where parseURI' = parseURI laxURIParserOptions . encodeUtf8         parseRelativeRef' = parseRelativeRef laxURIParserOptions . encodeUtf8 
Text/Atom/Types.hs view
@@ -32,7 +32,7 @@  -- {{{ Imports import           Data.NonNull-import           Data.Text           hiding (map)+import           Data.Text            import           Data.Time.Clock import           Data.Time.LocalTime () import           GHC.Generics
atom-conduit.cabal view
@@ -1,5 +1,5 @@ name: atom-conduit-version: 0.5.0.0+version: 0.5.0.1 cabal-version: >=1.10 build-type: Simple license: PublicDomain@@ -17,6 +17,11 @@     type: git     location: git://github.com/k0ral/atom-conduit.git +flag enable-hlint-test+  description: Enable hlint test-suite+  manual: True+  default: False+ library     exposed-modules:         Text.Atom.Conduit.Parse@@ -51,7 +56,6 @@         conduit-combinators >=1.0.5,         data-default -any,         safe-exceptions -any,-        hlint -any,         lens-simple -any,         mono-traversable >=1.0.0.1,         parsers -any,@@ -65,5 +69,18 @@         uri-bytestring >=0.2,         xml-conduit >=1.4,         xml-types -any+    default-language: Haskell2010+    hs-source-dirs: test++test-suite hlint+    if flag(enable-hlint-test)+      buildable: True+    else+      buildable: False+    type: exitcode-stdio-1.0+    main-is: HLint.hs+    build-depends:+        base >=4.8,+        hlint -any     default-language: Haskell2010     hs-source-dirs: test
+ test/HLint.hs view
@@ -0,0 +1,8 @@+import qualified Language.Haskell.HLint as HLint (hlint)+import           System.Exit+++main :: IO ()+main = do+  result <- HLint.hlint [ "test/", "Text/" ]+  if null result then exitSuccess else exitFailure
test/Main.hs view
@@ -16,7 +16,6 @@ import           Data.Time.Clock import           Data.Void import           Data.XML.Types-import qualified Language.Haskell.HLint       as HLint (hlint) import           Lens.Simple import           Test.QuickCheck.Instances import           Test.Tasty@@ -35,7 +34,6 @@ main = defaultMain $ testGroup "Tests"   [ unitTests   , properties-  , hlint   ]  unitTests :: TestTree@@ -152,11 +150,6 @@           , "</feed>"           ] --hlint :: TestTree-hlint = testCase "HLint check" $ do-  result <- HLint.hlint [ "test/", "Text/" ]-  Prelude.null result @?= True  roundtripProperty :: Eq a => Arbitrary a => Show a                   => TestName -> (a -> Source Maybe Event) -> ConduitM Event Void Maybe (Maybe a) -> TestTree