Unit Testing in iOS with XCTest

Опубликовано: 19 Август 2024
на канале: Etisha Garg
2,055
85

In this video, I've explained how to write unit tests in Xcode using XCTest framework. It not just cover the basics but also deep dives into the implementation with a sample SwiftUI project. If you're a beginner at unit testing or want to learn about how to write unit tests for a SwiftUI project, then this video is a must watch.

This video covers all the aspects of Unit testing be it how to setup unit test target, how to setup unit test classes, what is XCTestCase, how to write unit test using AAA approach, how to run unit tests, code coverage and much more.

► Checkout my blog on Unit Testing in Swift here:
https://www.swiftanytime.com/blog/uni...

► Project Source Code: https://github.com/SwiftAnytime/UnitT...

#swiftui #ios #unittesting

=========================================

⏱ Timestamps:
(00:00) Intro
(00:08) What are Unit Tests in Swift?
(00:47) How to setup Unit Test target in Xcode?
(01:39) How to include Unit Test target in an existing Xcode project?
(02:08) Sample SwiftUI project setup
(04:53) How to setup Unit Test classes?
(06:26) What is XCTestCase?
(06:47) More about @testable import
(08:09) setUp() and tearDown() functions
(09:34) How to write Unit Tests in Swift?
(13:18) How to run Unit Tests in Xcode?
(14:46) Unit Tests Code Coverage
(17:51) Outro

If you're an iOS developer who's determined to stand out in your next iOS interview, checkout the following resources and get a FLAT 15% discount using the coupon code: ETISHA-15

► Cracking the iOS Interview eBook: https://www.swiftanytime.com/cracking...
► Cracking Mobile System Design Interview Course: https://www.swiftanytime.com/cracking...

► For more content like this, subscribe to my channel:    / etishagarg  

► Join the Swift Anytime community: https://www.swiftanytime.com/community

► Follow Me On Social Media
LinkedIn:   / etisha-garg  
Twitter:   / gargetisha  
Instagram:   / gargetisha  

► For business inquiries, reach us on: [email protected]


Смотрите видео Unit Testing in iOS with XCTest онлайн без регистрации, длительностью часов минут секунд в хорошем качестве. Это видео добавил пользователь Etisha Garg 19 Август 2024, не забудьте поделиться им ссылкой с друзьями и знакомыми, на нашем сайте его посмотрели 2,055 раз и оно понравилось 85 людям.