Swift Testing

Open-source Swift projects categorized as Testing

Top 23 Swift Testing Projects

  • Quick

    The Swift (and Objective-C) testing framework.

    Project mention: GitHub can't be trusted. Or, how suspending Russian accounts deleted project history and pull requests | reddit.com/r/coding | 2022-04-20

    Take this example mentioned in the blog post. It was merged into Quick:main from younata:fix_parallel_tests - until the PR was merged, the code resided in the user younata's profile. That's the point of PRs, right? It can't be merged into Quick unless it passes review and is merged. Therefore, when the (allegedly) Russian user's profile was removed it removed all of the commits on their profile - including anything un-merged. Anything already merged, and thus merged to the Quick project repository, has not been changed.

  • Nimble

    A Matcher Framework for Swift and Objective-C

  • Appwrite

    Appwrite - The Open Source Firebase alternative introduces iOS support. Appwrite is an open source backend server that helps you build native iOS applications much faster with realtime APIs for authentication, databases, files storage, cloud functions and much more!

  • SnapshotTesting

    📸 Delightful Swift snapshot testing.

    Project mention: SwiftUI has so many awesome features!! And none of them seem to play well with unit tests :( Am I missing something? | reddit.com/r/SwiftUI | 2022-04-05
  • UI Testing Cheat Sheet

    How do I test this with UI Testing?

  • Fakery

    :alien: Swift fake data generator

    Project mention: I want random generated names, and I need your advice | reddit.com/r/swift | 2022-02-27

    I know that https://github.com/kleiram/Faker and https://github.com/vadymmarkov/Fakery, maybe other libraries exist. I use similar libraries in Python for data science and analytics testing. They are available from Cocoapods.

  • Cuckoo

    Boilerplate-free mocking framework for Swift! (by Brightify)

    Project mention: Swift Mocking Tools. To Use, or Not to Use, That Is the Question | reddit.com/r/u_Evolvice | 2022-09-08

    Additional setup: The cuckoo installation process requires adding a new run script into your test target build phases. Include the absolute path to each file and the framework that will generate mocks in this script. Import the generated file into the project once, and then re-generate it to keep it up to date. Class name starts from the word ‘Mock’ — each test double you can use as mock, stub, or spy.

  • ViewInspector

    Runtime introspection and unit testing of SwiftUI views (by nalexn)

    Project mention: Top swift libraries and why? | reddit.com/r/swift | 2022-06-10

    ViewInspector is a great library for testing SwiftUI views, without the heavy lifting of XCUI tests. You can quickly test view state changes, assert view colors or fonts etc. Almost any property can be tested, so that you know a view behaves as it should.

  • SonarLint

    Clean code begins in your IDE with SonarLint. Up your coding game and discover issues early. SonarLint is a free plugin that helps you find & fix bugs and security issues from the moment you start writing code. Install from your favorite IDE marketplace today.

  • Mockingjay

    An elegant library for stubbing HTTP requests with ease in Swift

  • RandomKit

    Random data generation in Swift

  • SwiftCheck

    QuickCheck for Swift

  • UIFontComplete

    Font management (System & Custom) for iOS and tvOS

  • Sizes

    View your app on different device and font sizes

  • WKZombie

    WKZombie is a Swift framework for iOS/OSX to navigate within websites and collect data without the need of User Interface or API, also known as Headless browser. It can be used to run automated tests / snapshots and manipulate websites using Javascript.

  • swift-corelibs-xctest

    The XCTest Project, A Swift core library for providing unit test support

  • SwiftyMocky

    Framework for automatic mock generation. Adds a set of handy methods, simplifying testing. One of the best and most complete solutions, including generics support and much more.

    Project mention: iOS unit test mocking using SwiftyMocky | dev.to | 2022-11-27
  • Mocker

    Mock Alamofire and URLSession requests without touching your code implementation

    Project mention: Looking for sources to learn advanced unit testing. | reddit.com/r/iOSProgramming | 2022-06-23

    For mocking data you can use something like Mocker (https://github.com/WeTransfer/Mocker) which I’ve found to be pretty easy to get started with.

  • Sleipnir

    BDD-style framework for Swift

  • Buildasaur

    Automatic testing of your Pull Requests on GitHub and BitBucket using Xcode Server. Keep your team productive and safe. Get up and running in minutes. @buildasaur

  • Kakapo

    🐤Dynamically Mock server behaviors and responses in Swift

  • DVR

    Network testing for Swift

  • NaughtyKeyboard

    The Big List of Naughty Strings is a list of strings which have a high probability of causing issues when used as user-input data. This is a keyboard to help you test your app from your iOS device.

  • Mockingbird

    A Swifty mocking framework for Swift and Objective-C. (by birdrides)

  • Erik

    Erik is an headless browser based on WebKit. An headless browser allow to run functional tests, to access and manipulate webpages using javascript.

  • InfluxDB

    Build time-series-based applications quickly and at scale.. InfluxDB is the Time Series Platform where developers build real-time applications for analytics, IoT and cloud-native services. Easy to start, it is available in the cloud or on-premises.

NOTE: The open source projects on this list are ordered by number of github stars. The number of mentions indicates repo mentiontions in the last 12 Months or since we started tracking (Dec 2020). The latest post mention was on 2022-11-27.

Swift Testing related posts


What are some of the best open-source Testing projects in Swift? This list will help you:

Project Stars
1 Quick 9,612
2 Nimble 4,611
3 SnapshotTesting 3,029
4 UI Testing Cheat Sheet 2,114
5 Fakery 1,676
6 Cuckoo 1,552
7 ViewInspector 1,508
8 Mockingjay 1,471
9 RandomKit 1,469
10 SwiftCheck 1,396
11 UIFontComplete 1,319
12 Sizes 1,220
13 WKZombie 1,138
14 swift-corelibs-xctest 1,023
15 SwiftyMocky 916
16 Mocker 912
17 Sleipnir 846
18 Buildasaur 774
19 Kakapo 766
20 DVR 650
21 NaughtyKeyboard 589
22 Mockingbird 551
23 Erik 548
Build time-series-based applications quickly and at scale.
InfluxDB is the Time Series Platform where developers build real-time applications for analytics, IoT and cloud-native services. Easy to start, it is available in the cloud or on-premises.