From 59ef9b1eb4031d591bf5aa7465cf46a690cdf689 Mon Sep 17 00:00:00 2001 From: Rob Rix Date: Thu, 5 Nov 2015 11:36:30 -0500 Subject: [PATCH] Test returning to the root. --- prototype/DoubtTests/LocationTests.swift | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/prototype/DoubtTests/LocationTests.swift b/prototype/DoubtTests/LocationTests.swift index e1c0a3a97..102f1be15 100644 --- a/prototype/DoubtTests/LocationTests.swift +++ b/prototype/DoubtTests/LocationTests.swift @@ -39,6 +39,10 @@ final class LocationTests: XCTestCase { func testCanMoveBackUpwardsFromDeepExplorations() { assert(term.explore().down?.right?.right?.down?.right?.up?.up?.it, ==, term) } + + func testCanReturnToStartOfExplorationFromArbitrarilyDeepNodes() { + assert(term.explore().down?.right?.right?.down?.right?.root.it, ==, term) + } }