teratail header banner
teratail header banner
質問するログイン新規登録

回答編集履歴

2

再修正

2019/11/05 06:24

投稿

MasakiHori
MasakiHori

スコア3391

answer CHANGED
@@ -40,7 +40,7 @@
40
40
 
41
41
  let vc = ViewController()
42
42
 
43
- let exp= expectation(description: "Hoge")
43
+ let exp = expectation(description: "Hoge")
44
44
 
45
45
  vc.HttpRequest(sentence: "Word") { _ in
46
46
  exp.fulfill()

1

修正

2019/11/05 06:24

投稿

MasakiHori
MasakiHori

スコア3391

answer CHANGED
@@ -40,13 +40,13 @@
40
40
 
41
41
  let vc = ViewController()
42
42
 
43
- let expectation = expectation(description: "Hoge")
43
+ let exp= expectation(description: "Hoge")
44
44
 
45
45
  vc.HttpRequest(sentence: "Word") { _ in
46
- expectation.fulfill()
46
+ exp.fulfill()
47
47
  }
48
48
 
49
- wait(for: [expectation], timeout: 10.0)
49
+ wait(for: [exp], timeout: 10.0)
50
50
  }
51
51
  ```
52
52