yesod-static 1.5.0.2 → 1.5.0.3
raw patch · 2 files changed
+4/−4 lines, 2 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
Files
- test/GeneratorTestUtil.hs +3/−3
- yesod-static.cabal +1/−1
test/GeneratorTestUtil.hs view
@@ -5,7 +5,7 @@ import Control.Monad (when) import Data.List (sortBy) import Language.Haskell.TH-import Test.HUnit+import Test.HUnit hiding (Location) import Yesod.EmbeddedStatic.Types import qualified Data.ByteString.Lazy as BL @@ -38,11 +38,11 @@ testOneEntry name loc ct [e] = testEntry name loc ct e testOneEntry _ _ _ _ = [| GenError "not exactly one entry" |] --- | Tests a list of entries +-- | Tests a list of entries testEntries :: [(Maybe String, Location, IO BL.ByteString)] -> [Entry] -> ExpQ testEntries a b | length a /= length b = [| [GenError "lengths differ"] |] testEntries a b = listE $ zipWith f a' b'- where + where a' = sortBy (\(_,l1,_) (_,l2,_) -> compare l1 l2) a b' = sortBy (\e1 e2 -> ebLocation e1 `compare` ebLocation e2) b f (name, loc, ct) e = testEntry name loc ct e
yesod-static.cabal view
@@ -1,5 +1,5 @@ name: yesod-static-version: 1.5.0.2+version: 1.5.0.3 license: MIT license-file: LICENSE author: Michael Snoyman <michael@snoyman.com>