]> code.delx.au - offlineimap/commitdiff
Fix to prop_allChangesToChild
authorJohn Goerzen <jgoerzen@complete.org>
Thu, 29 May 2008 07:13:42 +0000 (02:13 -0500)
committerJohn Goerzen <jgoerzen@complete.org>
Thu, 29 May 2008 07:13:42 +0000 (02:13 -0500)
testsrc/runtests.hs

index f00dc9bf1cbee1bd55bf9af308986cf4ca8a66d7..0b7f44aba397cb0bb42463f8a6a19af398f6503c 100644 (file)
@@ -71,16 +71,7 @@ prop_allChangesToChild master child =
               Just x -> if x /= v
                         then (k, x) : accum
                         else accum
-        masterChanges = map (pairToFunc ModifyContent) . catMaybes .
-                        map checkIt . Map.toList . Map.intersection child
-                            $ master
-            where checkIt (k, v) = 
-                      case Map.lookup k master of
-                        Nothing -> Nothing
-                        Just v' -> if v /= v'
-                                   then Just (k, v)
-                                   else Nothing
-        in (sort masterChanges, expectedResChild) @=?
+        in ([], expectedResChild) @=?
            (sort resMaster, sort resChild)
 
 prop_allChangesToMaster :: SyncCollection Int Word8 -> SyncCollection Int Word8 -> Result