cats
cats copied to clipboard
Add doctests (excellent first-time issue)
Doctests are a great way to provide compilable and testable example code for scaladoc. We should cover as many methods with doctests as possible.
Here is an example of PR adding doctests.
Note that to test the doctests run sbt coreJVM/test
This issue encompasses the effort of adding more doctest coverage to our type classes and data types.
It would be a great first-time contribution.
If you are interested, please comment here on what type classes or data types you'd like to work on.
@kailuowang I'll start working on Functor
:)
I'll be writing them for Semigroup
, Group
, and Monoid
.
Kleisli
seems pretty barren w.r.t doctests, I can start on that one?
@kailuowang So since Kleisli implements quite a few typeclasses, how much doctesting is too much? Should every method be covered? EDIT: I guess you can never have too much test coverage
@nasadorian hmm, good question. I think I would focus on methods that are not part of type classes. There a couple of them in KleisliFunctions
. Thanks!
A little late, but I did not forget! PR is linked... added a handful of doctests and comments to Kleisli! @kailuowang
Hi @kailuowang can i start for Applicatives
?
@kailuowang can I start with OptionT
?
@vasiliybondarenko go right ahead!
@kailuowang i checked Applicative
. That was done previously. I will work on EitherT
.
@kailuowang i will start Validated
.
@kailuowang i checked Ior
data type. that was interesting and good opportunity to learn. I will start Ior
.
@kailuowang i checked the Chain
data type as it used widely in cats and i like to add more doctest to it to learn more.
I'll pick Show