Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

スレッドブロックのセッションに非同期テスト対応を明記 #61

Merged
merged 2 commits into from
Jan 16, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions Documentation/ThreadBlock.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ static func syncFetchWeather(_ jsonString: String) throws -> String
## 課題
- 呼び出しAPIを`Sync ver`に変更する
- APIの処理が戻るまで[UIActivityIndicatorView](https://developer.apple.com/documentation/uikit/uiactivityindicatorview)を表示する
- テストがパスすることを確認する

※イメージ
![thread block](Images/ThreadBlock.gif)
Expand All @@ -20,5 +21,9 @@ iOSアプリで時間のかかる処理をするのにどうしたら良いか

- [iOSアプリで時間のかかる処理をする](https://zenn.dev/yumemi_inc/articles/ios-ui-thread)

非同期テストが必要になった場合には公式のドキュメントが用意されています。

- [Asynchronous Tests and Expectations](https://developer.apple.com/documentation/xctest/asynchronous_tests_and_expectations)

## 附録
[関連ワード・動画索引(熊谷さんのやさしい Swift 勉強会)](https://yumemi.notion.site/b7b5ae4ba0074668acee26de28679ea2)