//===----------------------------------------------------------------------===// // // This source file is part of the Swift Algorithms open source project // // Copyright (c) 2020 Apple Inc. and the Swift project authors // Licensed under Apache License v2.0 with Runtime Library Exception // // See https://swift.org/LICENSE.txt for license information // //===----------------------------------------------------------------------===// import XCTest @testable import Algorithms final class RotateTests: XCTestCase { /// Tests the example given in the `_reverse(subrange:until:)` documentation. func testUnderscoreReverse() { var input = [ "a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", ] let limit: Int = 4 let (lower, upper) = input._reverse( subrange: input.startIndex..