From d2964581da6b093f8bfa6b20e8882aed63dcc4db Mon Sep 17 00:00:00 2001 From: Jared Tobin Date: Thu, 10 Oct 2019 10:20:25 +0400 Subject: [PATCH] tests: replace bogus queue in test-qeu Per yosoyubik's commentary in urbit/urbit#1799: The test is expecting that qeu to not be correct.. when it is. The test [98 [97 ~ ~] [100 ~ [99 ~ ~]]] is a correct queue if we look at vertical ordering: (mor 98 97), (mor 98 100) & (mor 100 99) all return %.y, so vertical ordering is correct. The previous implementation of +apt:to checked only horizontal ordering between siblings, in this case that would fail: (mor 97 100) returns %.n, but that is not how you check correctness of hoon treaps. The solution is to modify that test with a proper "incorrect" +qeu, for example: ((soft (qeu)) [97 [98 ~ ~] [100 ~ [99 ~ ~]]]). Vertical ordering is not correct with any of the children. --- pkg/arvo/tests/sys/hoon/molds.hoon | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/arvo/tests/sys/hoon/molds.hoon b/pkg/arvo/tests/sys/hoon/molds.hoon index f2c9a9315..2be9fcb02 100644 --- a/pkg/arvo/tests/sys/hoon/molds.hoon +++ b/pkg/arvo/tests/sys/hoon/molds.hoon @@ -30,6 +30,6 @@ :: %+ expect-eq !> ~ - !> ((soft (qeu)) [98 [97 ~ ~] [100 ~ [99 ~ ~]]]) + !> ((soft (qeu)) [97 [98 ~ ~] [100 ~ [99 ~ ~]]]) == --