iproute icon indicating copy to clipboard operation
iproute copied to clipboard

iproute-1.7.6 test suite failures

Open peti opened this issue 6 years ago • 2 comments

Citing from https://hydra.nixos.org/build/85819909:

Running 2 test suites...
Test suite doctest: RUNNING...
./Data/IP/Op.hs:61: failure in expression `makeAddrRange ("2001:DB8::1" :: IPv6) 16 >:> makeAddrRange "2001:DB8::1" 32'
expected: True
 but got: *** Exception: IPv4 adddress

./Data/IP/Op.hs:77: failure in expression `("2001:DB8::1" :: IPv6) `isMatchedTo` makeAddrRange "2001:DB8::1" 32'
expected: True
 but got: *** Exception: IPv4 adddress

./Data/IP/Op.hs:118: failure in expression `addrRangePair ("2000::/8" :: AddrRange IPv6)'
expected: (2000::,8)
 but got: *** Exception: IPv6 address4

./Data/IP/Range.hs:25: failure in expression `(read "2001:db8:00:00:00:00:00:01/48" :: IPRange) == IPv6Range (read "2001:db8:00:00:00:00:00:01/48" :: AddrRange IPv6)'
expected: True
 but got: *** Exception: IPv4 adddress

./Data/IP/Range.hs:49: failure in expression `read "2001:db8:00:00:00:00:00:01/48" :: AddrRange IPv6'
expected: 2001:db8::/48
 but got: *** Exception: IPv4 adddress

./Data/IP/Addr.hs:29: failure in expression `(read "2001:db8:00:00:00:00:00:01" :: IP) == IPv6 (read "2001:db8:00:00:00:00:00:01" :: IPv6)'
expected: True
 but got: *** Exception: IPv4 adddress

./Data/IP/Addr.hs:40: failure in expression `(read "2001:db8:00:00:00:00:00:01" :: IP) == (read "2001:db8:00:00:00:00:00:01" :: IP)'
expected: True
 but got: *** Exception: IPv4 adddress

./Data/IP/Addr.hs:94: failure in expression `read "2001:db8:00:00:00:00:00:01" :: IPv6'
expected: 2001:db8::1
 but got: *** Exception: IPv4 adddress

Examples: 69  Tried: 54  Errors: 0  Failures: 8
Test suite doctest: FAIL
Test suite logged to: dist/test/iproute-1.7.6-doctest.log
Test suite spec: RUNNING...

IP
  read
    IPv4
      +++ OK, passed 100 tests.
    IPv6 FAILED [1]
    IPv4 failure FAILED [2]
    IPv6 failure FAILED [3]
    can read even if unnecessary spaces exist
    can read even if unnecessary spaces exist
RouteTable
  fromList
    creates the same tree for random input and ordered input
      +++ OK, passed 100 tests.
    creates the same tree for random input and ordered input
      +++ OK, passed 100 tests.
    stores input in the incremental order
      +++ OK, passed 100 tests.
    stores input in the incremental order
      +++ OK, passed 100 tests.
  toList
    expands as sorted
      +++ OK, passed 100 tests.
    expands as sorted
      +++ OK, passed 100 tests.
  folds
    foldl
      +++ OK, passed 100 tests.
    foldr
      +++ OK, passed 100 tests.
  monoid
    monoid instance
      +++ OK, passed 100 tests.

Failures:

  test/IPSpec.hs:54:9: 
  1) IP.read IPv6
       uncaught exception: ErrorCall
       IPv6 address4
       (after 2 tests)
         8d2:97a7:80bb:a60d:e1b0::/76

  To rerun use: --match "/IP/read/IPv6/"

  test/IPSpec.hs:55:9: 
  2) IP.read IPv4 failure
       uncaught exception: ErrorCall
       IPv4 mask length
       (after 1 test)
         Iv4 "80.123.62.105/4898895715847704126"

  To rerun use: --match "/IP/read/IPv4 failure/"

  test/IPSpec.hs:56:9: 
  3) IP.read IPv6 failure
       uncaught exception: ErrorCall
       IPv6 mask length: 4898895797153211166
       (after 1 test)
         Iv6 "d250:df7b:b63e:1f69:99e6:f2c2:f0de:d466/4898895797153211166"

  To rerun use: --match "/IP/read/IPv6 failure/"

Randomized with seed 97975516

Finished in 0.1460 seconds
15 examples, 3 failures
Test suite spec: FAIL

peti avatar Dec 10 '18 21:12 peti

This is a trap of MonadFail. I need to learn the MonadFail proposal more deeply.

kazu-yamamoto avatar Dec 11 '18 03:12 kazu-yamamoto

I uploaded a new version appar. So, this issue should be fixed.

kazu-yamamoto avatar Dec 11 '18 05:12 kazu-yamamoto