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

Adding FiniteDuration instances #2544

Merged
merged 9 commits into from
Oct 7, 2018

Conversation

calvinbrown085
Copy link
Contributor

closes #2517

@codecov-io
Copy link

codecov-io commented Sep 29, 2018

Codecov Report

Merging #2544 into master will increase coverage by 0.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2544      +/-   ##
==========================================
+ Coverage   95.18%   95.19%   +0.01%     
==========================================
  Files         359      361       +2     
  Lines        6558     6575      +17     
  Branches      285      289       +4     
==========================================
+ Hits         6242     6259      +17     
  Misses        316      316
Impacted Files Coverage Δ
...n/scala/cats/kernel/instances/finiteDuration.scala 100% <100%> (ø)
...src/main/scala/cats/instances/finiteDuration.scala 100% <100%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4880fd0...33cf30d. Read the comment docs.

Copy link
Member

@LukaJCB LukaJCB left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we also add these to cats-core? :)

@calvinbrown085
Copy link
Contributor Author

@LukaJCB Yes! I'll get those added

@LukaJCB
Copy link
Member

LukaJCB commented Sep 29, 2018

I'm sorry I think worded myself incorrectly, what I meant was, that we should re-export the instances in cats.instances and cats.implicits not duplicate them. :)

You can look at other instances in kernel to see how it's done.

@calvinbrown085
Copy link
Contributor Author

Ah, yeah I think that’s my bad. I probably should have thought of that before duplicating. I’ll get that fixed here :)

@calvinbrown085
Copy link
Contributor Author

@LukaJCB There we go, this should look a little better.

Copy link
Member

@LukaJCB LukaJCB left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@calvinbrown085
Copy link
Contributor Author

@LukaJCB Thank you, I got those added

@calvinbrown085
Copy link
Contributor Author

Anyone more familiar with this repo than me, why is the CodeCov pipeline failing?

Am I missing some tests?

@LukaJCB
Copy link
Member

LukaJCB commented Sep 30, 2018

@calvinbrown085 You're not testing any of the instances for their laws. Check the LawTests class to see how it's done for other types.

@@ -14,6 +14,7 @@ trait AllInstances
with EqInstances
with EitherInstances
with DurationInstances
with FiniteDurationInstances
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is binary incompatible, you should create another AllInstancesBinCompat0 trait here, and then mix that into all. :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, that might be what I am missing :) Thank you

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Of course :)

Copy link
Member

@LukaJCB LukaJCB left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, thank you! :)

Copy link
Contributor

@kailuowang kailuowang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@LukaJCB LukaJCB merged commit ee2b5ee into typelevel:master Oct 7, 2018
@kailuowang kailuowang added this to the 1.5 milestone Oct 30, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add FiniteDuration instances
4 participants