-
Notifications
You must be signed in to change notification settings - Fork 780
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
Add tests for RotationDesignable #no-public-changes #476
Conversation
Generated by 🚫 Danger |
|
||
// MARK: - MockRotationDesignable | ||
|
||
protocol MockRotationDesignable: class, RotationDesignable { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Won't we need these mocks in others tests? For example, to test mixing designable properties. Won't be better to create a file by mock? (just wondering, up to you)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure what you mean by creating a file by mock. Right now I'm testing each protocol and creating a mock for that protocol. One protocol per file.
As for testing mixing designable properties... basically, you're talking about one designable protocol affecting the performance of another designable protocol? That's an interesting point you bring up. I'm just testing the individual components right now... mixing them does add another degree of complexity.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You got my point. I think the main point to do mixing tests is your mock, it shouldn't be too complicated with your architecture (besides the complexity of the test itself). Saying that I'm wondering if we should put out each mock protocol (in their own files) to make easier to find them when we will start to work on mixing tests.
Since they are internal, it will work as expected, but it may be harder to find them in the project when we will need them in other context.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see what you're saying.
I know each file we add will add like 3-4 seconds on to the build time though!
I'm open to doing this but I think mixing tests is a little way down the road.
-- I started to write a long response regarding mixing tests... a lot going through my mind now. You just had to bring this up!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can continue this discussion when we will start mixing tests, for now, it's not blocking this PR!
73e9d4f
to
b0d178f
Compare
b0d178f
to
81df3d6
Compare
#434 - marking this for record keeping |
Summary of Pull Request:
RotationDesignable
conforming classes.