8
8
See http://swift.org/CONTRIBUTORS.txt for Swift project authors
9
9
*/
10
10
11
+ import XCTest
12
+
11
13
import struct Utility. Path
12
14
import func Utility. fopen
13
15
import func Utility. fputs
14
- import func libc. sleep
15
16
import enum POSIX. Error
16
17
import func POSIX. popen
17
- import XCTest
18
18
19
19
class MiscellaneousTestCase : XCTestCase {
20
20
@@ -276,10 +276,6 @@ class MiscellaneousTestCase: XCTestCase {
276
276
var output = try popen ( execpath)
277
277
XCTAssertEqual ( output, " Hello \n " )
278
278
279
- // we need to sleep at least one second otherwise
280
- // llbuild does not realize the file has changed
281
- sleep ( 1 )
282
-
283
279
try fopen ( prefix, " Bar/Bar.swift " , mode: . write) { fp in
284
280
try fputs ( " public let bar = \" Goodbye \" \n " , fp)
285
281
}
@@ -302,10 +298,6 @@ class MiscellaneousTestCase: XCTestCase {
302
298
var output = try popen ( execpath)
303
299
XCTAssertEqual ( output, " ♣︎K \n ♣︎Q \n ♣︎J \n ♣︎10 \n ♣︎9 \n ♣︎8 \n ♣︎7 \n ♣︎6 \n ♣︎5 \n ♣︎4 \n " )
304
300
305
- // we need to sleep at least one second otherwise
306
- // llbuild does not realize the file has changed
307
- sleep ( 1 )
308
-
309
301
try fopen ( prefix, " app/Packages/FisherYates-1.2.3/src/Fisher-Yates_Shuffle.swift " , mode: . write) { fp in
310
302
try fputs ( " public extension Collection{ func shuffle() -> [Iterator.Element] {return []} } \n \n public extension MutableCollection where Index == Int { mutating func shuffleInPlace() { for (i, _) in enumerated() { self[i] = self[0] } }} \n \n public let shuffle = true " , fp)
311
303
}
@@ -328,10 +320,6 @@ class MiscellaneousTestCase: XCTestCase {
328
320
var output = try popen ( execpath)
329
321
XCTAssertEqual ( output, " Hello \n " )
330
322
331
- // we need to sleep at least one second otherwise
332
- // llbuild does not realize the file has changed
333
- sleep ( 1 )
334
-
335
323
try fopen ( prefix, " root/Packages/dep1-1.2.3/Foo.swift " , mode: . write) { fp in
336
324
try fputs ( " public let foo = \" Goodbye \" " , fp)
337
325
}
0 commit comments