Mockingbird v0.12.0 Release Notes
Release Date: 2020-05-07 // almost 3 years ago-
Targets
- Xcode 11.4 / Swift 5.2
- π iOS 8.0+, macOS 10.14+, tvOS 9.0+
Migrating from 0.11
π€‘ Mocking class constrained protocols without designated initializers now uses protocol mocking instead of class mocking
protocol MyProtocol: AnyObject {}// Oldmock(MyProtocol.self).initialize()// Newmock(MyProtocol.self)
π The convenience non-parameterized closure stubbing operator has been removed; convert implicit argument closure stubs to explicitly ignore arguments
// Oldgiven(myMock.doSomething(with: any())) ~> { print("Ignoring arguments") }// Newgiven(myMock.doSomething(with: any())) ~> { _ in print("Ignoring arguments") }
π New Features
- β Add ability to provide default values for unstubbed methods (#80)
Andrew Chang | Sterling Hackley | Ryan Meisters - β Add support for diagnostic warnings and errors that integrate with Xcodeβs buildtime issues in the sidebar (#102)
Andrew Chang - β Add asset download command to improve supporting source file setup, usage
$ mockingbird download starter-pack
(#101)
Andrew Chang - β Add sequential stubbing for returning a sequence of predefined values (#90)
Andrew Chang - β Add support for stubbing and verifying subscripts (#89)
Andrew Chang | Pavel Ivashkov
β¨ Enhancements
- π¨ Refactor import and compilation directive parsing to use SwiftSyntax, resulting in faster code generation (#92)
Andrew Chang - β
Uniquify default generated file names when using the installer by prefixing the test target name (#100)
Andrew Chang
π Bug Fixes
- π Fix compatibility with Swift 5.2 (#91)
Andrew Chang - π Fix stubbing methods without parameters by removing the non-parameterized closure stubbing operator (#86)
Andrew Chang | seven332 - π Fix generating convenience initializers for class constrained protocols without a declared designated initializer
Andrew Chang - π Fix handling bash-style variables in build settings, e.g.
${TARGET_NAME}
(#83)
Andrew Chang - π Fix type inference for string literals and initialized types assigned to properties in class mocks (#108)
Andrew Chang | Ryan Meisters - π Fix mocking classes with designated and synthesized initializers, e.g. from
Decodable
(#93)
Andrew Chang | Tristan Diependael - π Fix synchronization of collection types in CLI and framework (#106)
Andrew Chang - π Fix uninstaller not removing
.generated.swift
source files added by the installer (#100)
Andrew Chang