Commit a1a9d8a8 authored by Michael Anthony Knyszek's avatar Michael Anthony Knyszek Committed by Brad Fitzpatrick
Browse files

runtime: add tests for runtime mTreap

This change exports the runtime mTreap in export_test.go and then adds a
series of tests which check that the invariants of the treap are
maintained under different operations. These tests also include tests
for the treap iterator type.

Also, we note that the find() operation on the treap never actually was
best-fit, so the tests just ensure that it returns an appropriately
sized span.

For #30333.

Change-Id: If81f7c746dda6677ebca925cb0a940134701b894
Reviewed-on: https://go-review.googlesource.com/c/go/+/164100


Run-TryBot: Michael Knyszek <mknyszek@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: default avatarAustin Clements <austin@google.com>
(cherry picked from commit d13a9312)
Reviewed-on: https://go-review.googlesource.com/c/go/+/173940


Reviewed-by: default avatarBrad Fitzpatrick <bradfitz@golang.org>
parent f1a077df
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment