mrkkrp / zip

Efficient library for manipulating zip archives
Other
81 stars 27 forks source link

zip-0.1.8 test suite failures #32

Closed peti closed 7 years ago

peti commented 7 years ago

Citing from http://hydra.nixos.org/build/49690809/nixlog/1/raw:

Failures:

  tests/Main.hs:326: 
  1) getEntryDesc always returns correct description
       Falsifiable (after 1 test): 
       predicate failed on: { edCompression = BZip2
       , edModTime = 2021-08-12 04:30:02 UTC
       , edUncompressedSize = 0
       , edComment = Just "\ENQ"
       , edExtraField = fromList [(0,"\SOH"),(1,"")] }
       EM "D" { edCompression = BZip2
       , edModTime = 2021-08-12 04:30:38 UTC
       , edUncompressedSize = 0
       , edComment = Just "\ENQ"
       , edExtraField = fromList [(0,"\SOH")] } <zip archive>

  tests/Main.hs:470: 
  2) setModTime, when mod time is set (after creation), reads it and updates
       predicate failed on: 1985-09-26 00:04:00 UTC (after 1 test): 
       1985-09-26 00:04:53 UTC
       "I"

  tests/Main.hs:535: 
  3) renameEntry, when renaming after editing of new entry, produces correct result
       Falsifiable (after 1 test): 
       predicate failed on: { edCompression = BZip2
       , edModTime = 2021-08-12 04:30:02 UTC
       , edUncompressedSize = 0
       , edComment = Just "\ENQ"
       , edExtraField = fromList [(0,"\SOH"),(1,"")] }
       EM "D" { edCompression = BZip2
       , edModTime = 2021-08-12 04:30:38 UTC
       , edUncompressedSize = 0
       , edComment = Just "\ENQ"
       , edExtraField = fromList [(0,"\SOH")] } <zip archive>
       "I"

  tests/Main.hs:543: 
  4) renameEntry, when renaming existing entry, gets renamed
       Falsifiable (after 1 test): 
       predicate failed on: { edCompression = BZip2
       , edModTime = 2021-08-12 04:30:02 UTC
       , edUncompressedSize = 0
       , edComment = Just "\ENQ"
       , edExtraField = fromList [(0,"\SOH"),(1,"")] }
       EM "D" { edCompression = BZip2
       , edModTime = 2021-08-12 04:30:38 UTC
       , edUncompressedSize = 0
       , edComment = Just "\ENQ"
       , edExtraField = fromList [(0,"\SOH")] } <zip archive>
       "I"

  tests/Main.hs:574: 
  5) forEntries affects all existing entries
       Falsifiable (after 1 test): 
       predicate failed on: fromList [("4",{ edCompression = Deflate
       , edModTime = 2075-06-17 19:06:02 UTC
       , edUncompressedSize = 0
       , edComment = Just "j"
       , edExtraField = fromList [(0,"\SOH"),(1,"")] })]
       EC (fromList [("4",{ edCompression = Deflate
       , edModTime = 2075-06-17 19:06:38 UTC
       , edUncompressedSize = 0
       , edComment = Just "\230"
       , edExtraField = fromList [(0,"\SOH")] })]) <zip archive>
       "j"

  tests/Main.hs:631: 
  6) consistency can save and restore arbitrary archive
       Falsifiable (after 1 test): 
       predicate failed on: fromList [("4",{ edCompression = Deflate
       , edModTime = 2075-06-17 19:06:02 UTC
       , edUncompressedSize = 0
       , edComment = Just "\230"
       , edExtraField = fromList [(0,"\SOH"),(1,"")] })]
       EC (fromList [("4",{ edCompression = Deflate
       , edModTime = 2075-06-17 19:06:38 UTC
       , edUncompressedSize = 0
       , edComment = Just "\230"
       , edExtraField = fromList [(0,"\SOH")] })]) <zip archive>
       "j"

Randomized with seed 1643803002

This occurs when building the package 32 bit platforms, i.e. i686 Linux.

mrkkrp commented 7 years ago

Thanks for the report, I'll take a look. The differences are always in time stamps and extra fields, it seems.

mrkkrp commented 7 years ago

Note: the extra (1,"") can be ignored, it's OK. The only difference in slightly-off time stamps.

mrkkrp commented 7 years ago

I believe I fixed the bug. Version 0.1.9 is coming.