Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[7/y] Fix stubbing nil values in Obj-C mocks #246

Merged
merged 1 commit into from
Jan 6, 2022

Conversation

andrewchang-bird
Copy link
Contributor

@andrewchang-bird andrewchang-bird commented Dec 24, 2021

Stack:
πŸ“š #248 [9/y] Fix nested optional codegen
πŸ“š #247 [8/y] Fix wildcard arg matching for Obj-C param types
πŸ“š #246 ← [7/y] Fix stubbing nil values in Obj-C mocks
πŸ“š #254 [6/y] Update example projects
πŸ“š #253 [5/y] Improve support for configuring SPM Xcode projects
πŸ“š #252 [4/y] Show help message no mockable types are generated
πŸ“š #251 [3/y] Fix unavailable generic protocol mock initializer
πŸ“š #250 [2/y] Fix generator caching for multi-project setups
πŸ“š #249 [1/y] Optimize dependency graph traversal
πŸ“š #245 Replace SwiftPM with Swift Argument Parser

Fixes #238 where stubbing a nil value for Objective-C mocks would incorrectly implicitly bridge to NSNull. Rather than passing a raw nil to Objective-C, we can instead use a custom representation NilValue and handle that case separately.

@andrewchang-bird andrewchang-bird added this to the Release 0.19 milestone Dec 24, 2021
@andrewchang-bird andrewchang-bird force-pushed the dev/andrewchang-bird/fix-objc-nil branch from 02586f8 to 40134ad Compare January 4, 2022 22:21
@andrewchang-bird andrewchang-bird changed the base branch from dev/andrewchang-bird/swift-argument-parser to dev/andrewchang-bird/update-example-projects January 4, 2022 22:23
@andrewchang-bird andrewchang-bird changed the title [1/x] Fix stubbing nil values in Obj-C mocks [7/y] Fix stubbing nil values in Obj-C mocks Jan 5, 2022
@andrewchang-bird andrewchang-bird force-pushed the dev/andrewchang-bird/update-example-projects branch from de2cd95 to ccc2444 Compare January 6, 2022 07:45
Base automatically changed from dev/andrewchang-bird/update-example-projects to master January 6, 2022 08:17
@andrewchang-bird andrewchang-bird force-pushed the dev/andrewchang-bird/fix-objc-nil branch from 40134ad to 8f243ee Compare January 6, 2022 08:18
@andrewchang-bird andrewchang-bird merged commit 5a5e732 into master Jan 6, 2022
@andrewchang-bird andrewchang-bird deleted the dev/andrewchang-bird/fix-objc-nil branch January 6, 2022 09:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Mocking an Optional property that unwraps to nil raises NSInvalidArgumentException
2 participants