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

Auto Mocks generator #600

Closed
Velin92 opened this issue Feb 20, 2023 · 1 comment · Fixed by #597
Closed

Auto Mocks generator #600

Velin92 opened this issue Feb 20, 2023 · 1 comment · Fixed by #597
Assignees
Labels
A-DevX Anything that can improve the DevX T-Task Team: Element X Platform

Comments

@Velin92
Copy link
Member

Velin92 commented Feb 20, 2023

We use a lot of mocks in the application both for Unit Testing, UI Testing and SwiftUI previews.

Would be nice to find a way to generate these mocks automatically so that we can both have spies for the values when they called/updated, for testing purposes, and a way to control the return values, so that we can still use them to tweak and change the behaviours to test for different given cases. And all of this without the need of writing the mocks ourselves.

We should use a mock generator system that isn't necessarily tied to XCTests, so that we can still use the mocks in the original target, and use them alongside UITests, Unit Tests and SwiftUI previews.

@Velin92 Velin92 added the A-DevX Anything that can improve the DevX label Feb 20, 2023
@Velin92 Velin92 self-assigned this Feb 20, 2023
@Velin92 Velin92 linked a pull request Feb 20, 2023 that will close this issue
@Velin92
Copy link
Member Author

Velin92 commented Feb 20, 2023

This has been proved to be easily possible! However for a while we won't need new mocks, and migrating to the new generated ones can take a bit, so we will give a higher priority to other tasks before completing this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-DevX Anything that can improve the DevX T-Task Team: Element X Platform
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant