Mockingbird v0.16.0 Release Notes
Release Date: 2020-10-08 // over 2 years ago-
Targets
- Xcode 12.0 / Swift 5.3
- π iOS 8.0+, macOS 10.14+, tvOS 9.0+
Migrating from 0.15
Thunk Pruning
The generator flag
--disable-thunk-stubs
has been replaced with the option--prune [disable|stub|omit]
. Specifydisable
for the thunk pruning method to reproduce the previous flag behavior.Level Description β disable
stub
Generate partial definitions filled with fatalError
.omit
Donβt generate any definitions for unused types. π New Features
- β Added the ability to pass ad hoc JSON project descriptions to the generator instead of a
.xcodeproj
file (#171)
Andrew Chang - β Added a thunk pruning option to fully exclude unused types from generating thunks (#174)
Andrew Chang - Added support for setting
GH_ACCESS_TOKEN
to address rate limiting when downloading prebuilt binaries (#169)
Andrew Chang
β¨ Enhancements
- π Improved support for Xcode 12 / Swift 5.3 and upgraded all dependency versions (#168)
Andrew Chang - π Improved handling of module names shadowed by top level nominal types (#172)
Andrew Chang
Previous changes from v0.15.0
-
Targets
- Xcode 11.6 / Swift 5.2
- π iOS 8.0+, macOS 10.14+, tvOS 9.0+
Migrating from 0.14
π€‘ Generic Mock Initialization
π This release unifies the mock initialization API for generic types.
class MyClass {}protocol MyProtocol {}class MyGenericClass\<T\> {}protocol MyGenericProtocol { associatedtype T}// Oldmock(MyClass.self)mock(MyProtocol.self)mock(MyGenericClassMock\<Bool\>.self)mock(MyGenericProtocolMock\<Bool\>.self)// Newmock(MyClass.self) // no changemock(MyProtocol.self) // no changemock(MyGenericClass\<Bool\>.self)mock(MyGenericProtocol\<Bool\>.self)
Value Provider Semantics
Value provider has been simplified and no longer allows for hierarchical composition and decomposition.
// Oldvar provider = ValueProvider() provider.addSubprovider(.standardProvider) provider.removeSubprovider(.standardProvider)// New (mutating)var provider = ValueProvider() provider.add(.standardProvider)// New (non-mutating)let provider = ValueProvider() + .standardProviderlet provider = ValueProvider().adding(.standardProvider)
π New Features
- π€‘ Unified generic mock initialization for classes and protocols (#157)
Andrew Chang | Jierong Li - π Improved ValueProvider value semantics (#159)
Andrew Chang - β Added custom header option to generator (#158)
Andrew Chang | Ryan Meisters
β¨ Enhancements
- β‘οΈ Updated code signing certificates and added CI action to build signed artifacts on commit with audit trail (#104)
Andrew Chang | Ryan Meisters