Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
テストはじめました.pdf
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
tiking
August 22, 2020
180
1
Share
テストはじめました.pdf
tiking
August 22, 2020
More Decks by tiking
See All by tiking
デザインシステムっていいな
tiking76
0
260
GraphQL 入門
tiking76
0
1.5k
みんなTCAって 知ってる?ver2.0
tiking76
1
370
みんなTCAって知ってる?
tiking76
0
1.1k
最近きてるかもって思ってるデザイン
tiking76
0
300
Swiftのちょっとうれしい構文
tiking76
0
140
p1assさんを作ろうと試みました
tiking76
0
170
PRのときに使われがちな略語のやつ
tiking76
0
150
swiftでもグラフ書いてみたくない??
tiking76
0
280
Featured
See All Featured
Scaling GitHub
holman
464
140k
A brief & incomplete history of UX Design for the World Wide Web: 1989–2019
jct
1
360
Fireside Chat
paigeccino
42
3.9k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
47
8.1k
Dominate Local Search Results - an insider guide to GBP, reviews, and Local SEO
greggifford
PRO
0
150
Taking LLMs out of the black box: A practical guide to human-in-the-loop distillation
inesmontani
PRO
3
2.1k
The Power of CSS Pseudo Elements
geoffreycrofte
82
6.2k
How to audit for AI Accessibility on your Front & Back End
davetheseo
0
270
Effective software design: The role of men in debugging patriarchy in IT @ Voxxed Days AMS
baasie
0
300
Claude Code どこまでも/ Claude Code Everywhere
nwiizo
65
55k
RailsConf 2023
tenderlove
30
1.4k
How to make the Groovebox
asonas
2
2.1k
Transcript
テストはじめました Zli×CA合同LT 2020/08/22 tiking
Readme name : 舘佳紀 colleage : 会津大学学部3年 さーくる : Zli所属です
Handlename : チキング 好きな言語 swift twitter @tikin0716 gitHub tiking76
みなさんテスト書いてますか??
テストってどんなのがあるの??
テストを書くことのメリット • 動作する綺麗なコードが書ける • もしバグが見つかってとしてテストがすぐに教えてくれるので、原因の特定がしやす く修正時間が短くなり手戻りが最小になります。 • 開発サイクル無いで常に動作保証があるので、安心して開発を進められる。 • 責務の切り分けが容易になる
今回やっていくのは 単体テストと機能テスト
単体テスト 単体テスト(ユニットテスト)は、一つのメソッドもしくは一つのクラスのテストを指します。 開発者の設計した通りに動くかを確認するテスト 開発者がテストを行います
実際にやってみた
機能テスト 機能テストは機能が仕様通りにきちんと動作しているかのテストを指します。 要件通りに動くかを確認するテストで、ユーザーもしくはビジネス要件を引き出し何をつく るを決定する役割の人が行うテストです。
モックオブジェクト 技法 テストのために、 インターフェースは本物と同じで中 身だけ偽物のオブジェクトを使う。
DI(Dependency Injection) : 依存性の注入 依存性をもったオブジェクトを外部からわた すこと。 デザインパターンの一種。
実際にやってみた
やってみての感想 ・テストって案外ハードル低いんだ… ・テストを意識して書いているとリファクタリングしやすいことが大きな気づきになった。
LT駆動開発最高!!
参考になりました ・さわって学べる! iOSテスト駆動開発 - shindyu - BOOTH ・単体テストのハジメ ・猿でも分かる! Dependency
Injection: 依存性の注入
ここまでありがとうございました