Files
swift-mirror/test/stdlib/LazySlice.swift
Ben Cohen 685f31b0e2 [stdlib] Migrate stdlib tests of Swift 3 (#17427)
* First sweep of Swift 3 stdlib test upgrades

* Review feedback

* Remove a handful more #if >=4.0

* Fix up Dictionary tests
2018-07-08 09:37:01 -07:00

18 lines
399 B
Swift

// RUN: %empty-directory(%t)
// RUN: %target-build-swift %s -o %t/a.out4 -swift-version 4 && %target-run %t/a.out4
// REQUIRES: executable_test
import StdlibUnittest
var tests = TestSuite("LazySlice")
tests.test("CommuteLazyness") {
let a = [1,2,3].lazy
let b = a[...]
var c = b.filter { $0 == 0 }
expectType(LazyFilterCollection<Slice<LazyCollection<[Int]>>>.self, &c)
}
runAllTests()