Slide 1

Slide 1 text

iOS #5 Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. Embedded frameworkΛར༻ͯ͠طଘϓϩδΣΫτͰ΋ര଎ͰTDD 2019.03.26[TUE] @LODGE Ϡϑʔגࣜձࣾ ৽ಊ ܟོ

Slide 2

Slide 2 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. ৽ಊ ܟོ ϠϑΦΫ! iOSΤϯδχΞ TDD, PairPrograming @shindyu

Slide 3

Slide 3 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. એ఻ʂ @ٕज़ॻయ̑ ͞Θֶͬͯ΂Δ! iOSςετۦಈ։ൃ https://booth.pm/ja/items/1040471

Slide 4

Slide 4 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. TDDͯ͠·͔͢ʁ

Slide 5

Slide 5 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. ϠϑΦΫ! iOS • 2010೥͔Β։ൃ։࢝ • Swift: ໿20ສߦ / Objc: ໿11ສߦ • 2017೥ࠒ͔Β։ൃख๏ʹXPಋೖ
 ɹˠ TDDʴϖΞϓϩ
 ɹˠ test 3500έʔεҎ্

Slide 6

Slide 6 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. XPΛಋೖ͔ͯ͠Β ϖΞϓϩɾϖΞϩʔς͢Δ͜ͱͰνʔϜͷٕज़ྗUP ίʔυϨϏϡʔͷετϨε͔Βղ์ TDDʹΑΔ৺ཧత҆શ

Slide 7

Slide 7 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. XPΛಋೖ͔ͯ͠Β ϖΞϓϩ͢Δ͜ͱͰνʔϜͷٕज़ྗUP ίʔυϨϏϡʔͷετϨε͔Βղ์ TDDʹΑΔ৺ཧత҆શ TDDͰ͸Red, Green, RefactorͷϦζϜ͕େࣄ

Slide 8

Slide 8 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. XPΛಋೖ͔ͯ͠Β ϖΞϓϩ͢Δ͜ͱͰνʔϜͷٕज़ྗUP ίʔυϨϏϡʔͷετϨε͔Βղ์ TDDʹΑΔ৺ཧత҆શ TDDͰ͸Red, Green, RefactorͷϦζϜ͕େࣄ ⚠ςετͷϏϧυ/࣮ߦ͕࣌ؒ૿Ճ⚠ → ϖΞϓϩͰͷίετ͸ഒ

Slide 9

Slide 9 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. CleanArchitecture + Embedded frameworkΛ࠾༻

Slide 10

Slide 10 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. CleanArchitecture + Embedded frameworkΛ࠾༻ CleanArchitectureͰ੹຿Λ෼ׂ → ੹຿͕෼ׂ͞ΕΔ͜ͱͰςετ͕༰қʹͳΔ ෼ׂͨ͠ϞδϡʔϧΛEmbedded frameworkʹ → λʔήοτ෼ׂ͢Δ͜ͱͰϏϧυ͕࣌ؒ୹ॖ͞ΕΔ → είʔϓ͕খ͘͞ͳͬͯࠩ෼Ϗϧυ΋ޮ͖΍͘͢ͳΔ

Slide 11

Slide 11 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. ܭଌ݁Ռ ΫϦʔϯϏϧυ࣌ؒʢFramework: 6000ߦʣ App: 530s Framework: 18s શςετ࣮ߦ࣌ؒʢApp: 3500case / Framework: 200caseʣ App: 102s Frameworkɿ1s

Slide 12

Slide 12 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. Project files • App • View / Repository / … • Domain • Presenter / UseCase / Entity / … • PresenterͷςετΛް͍ͨ͘͠ͷͰ
 ͋͑ͯFrameworkଆʹஔ͍͍ͯΔ • Ҏલ͸View͔ΒςετΛॻ͍͍͕ͯͨ Presenter͔Βॻ͘Α͏ʹͨ͠

Slide 13

Slide 13 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. How to TDD 1. PresenterTestsͰςετΛॻ͘ 2. PresenterTestsΛ௨͢ 3. UIͱPresenter,OutputΛܨ͙

Slide 14

Slide 14 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. How to TDD 1. PresenterTestsͰςετΛॻ͘ 2. PresenterTestsΛ௨͢ 3. UIͱPresenter,OutputΛܨ͙ Presenter, UseCase, Outputͷ InterfaceΛߟ͑Δ 1SFTFOUFS5FTUTTXJGU

Slide 15

Slide 15 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. How to TDD 1. PresenterTestsͰςετΛॻ͘ 2. PresenterTestsΛ௨͢ 3. UIͱPresenter,OutputΛܨ͙ PresenterProtocol, PresenterImpl, UseCaseProtocol, OutputProtocolͷ࣮૷

Slide 16

Slide 16 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. How to TDD 1. PresenterTestsͰςετΛॻ͘ 2. PresenterTestsΛ௨͢ 3. UIͱPresenter,OutputΛܨ͙ UIEvent → Presenter Output → UI൓ө

Slide 17

Slide 17 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. How to TDD 1. PresenterTestsͰςετΛॻ͘ 2. PresenterTestsΛ௨͢ 3. UIͱPresenter,OutputΛܨ͙ UIEvent → Presenter Output → UI൓ө ⌘+Ctrl+[ or ⌘+Ctrl+]

Slide 18

Slide 18 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. ·ͱΊ

Slide 19

Slide 19 text

Copyright © 2019 Yahoo Japan Corporation. All Rights Reserved. ·ͱΊ CleanArchitecture + Embedded FrameworkΛ࠾༻ͨ͠ طଘϓϩδΣΫτͰ΋ര଎ͰTDDग़དྷΔΑ͏ʹͳͬͨ ര଎TDDͰ։ൃޮ཰Upʂ ͝੩ௌ͋Γ͕ͱ͏͍͟͝·ͨ͠