Skip to content

Commit

Permalink
Use à la carte syntax imports
Browse files Browse the repository at this point in the history
  • Loading branch information
travisbrown committed Feb 20, 2020
1 parent 185b005 commit 510d139
Show file tree
Hide file tree
Showing 64 changed files with 129 additions and 65 deletions.
2 changes: 1 addition & 1 deletion free/src/test/scala/cats/free/FreeApplicativeSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import cats.instances.all._
import cats.kernel.Eq
import cats.laws.discipline.{ApplicativeTests, SerializableTests}
import cats.laws.discipline.SemigroupalTests.Isomorphisms
import cats.syntax.all._
import cats.syntax.apply._
import cats.tests.CatsSuite
import org.scalacheck.{Arbitrary, Gen}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ import cats.instances.all._
import cats.laws.discipline.{InvariantMonoidalTests, MiniInt, SerializableTests}
import cats.laws.discipline.arbitrary._
import cats.laws.discipline.SemigroupalTests.Isomorphisms
import cats.syntax.all._
import cats.syntax.invariant._
import cats.syntax.semigroupal._
import cats.tests.BinCodecInvariantMonoidalSuite._
import cats.tests.CatsSuite
import org.scalacheck.{Arbitrary, Gen}
Expand Down
2 changes: 1 addition & 1 deletion free/src/test/scala/cats/free/FreeSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import cats.kernel.Eq
import cats.laws.discipline.{DeferTests, FoldableTests, MonadTests, SerializableTests, TraverseTests}
import cats.laws.discipline.arbitrary.catsLawsArbitraryForFn0
import cats.laws.discipline.SemigroupalTests.Isomorphisms
import cats.syntax.all._
import cats.syntax.apply._
import cats.tests.CatsSuite
import org.scalacheck.{Arbitrary, Cogen, Gen}
import org.scalacheck.Arbitrary.arbFunction1
Expand Down
3 changes: 2 additions & 1 deletion free/src/test/scala/cats/free/FreeTSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ import cats.arrow.FunctionK
import cats.data._
import cats.instances.all._
import cats.laws.discipline._
import cats.syntax.all._
import cats.syntax.applicative._
import cats.syntax.either._
import cats.tests.CatsSuite
import org.scalacheck.{Arbitrary, Cogen, Gen}

Expand Down
2 changes: 1 addition & 1 deletion js/src/test/scala/cats/tests/FutureTests.scala
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import cats.kernel.Eq
import cats.kernel.laws.discipline.{MonoidTests => MonoidLawTests, SemigroupTests => SemigroupLawTests}
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.either._
import cats.tests.{CatsSuite, ListWrapper}
import org.scalacheck.{Arbitrary, Cogen}
import org.scalacheck.Arbitrary.arbitrary
Expand Down
2 changes: 1 addition & 1 deletion jvm/src/test/scala/cats/tests/FutureSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import cats.kernel.{Eq, Semigroup}
import cats.kernel.laws.discipline.{MonoidTests => MonoidLawTests, SemigroupTests => SemigroupLawTests}
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.either._
import cats.tests.{CatsSuite, ListWrapper}
import org.scalacheck.{Arbitrary, Cogen}
import org.scalacheck.Arbitrary.arbitrary
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@ import cats.kernel.laws.discipline.{EqTests, SemigroupTests}
import cats.laws.discipline._
import cats.laws.discipline.SemigroupalTests.Isomorphisms
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.foldable._
import cats.syntax.reducible._
import cats.syntax.show._

class NonEmptyStreamSuite extends CatsSuite {
// Lots of collections here.. telling ScalaCheck to calm down a bit
Expand Down
2 changes: 1 addition & 1 deletion tests/src/test/scala-2.13+/cats/tests/ArraySeqSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import cats.laws.discipline.{
TraverseTests
}
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.show._
import scala.collection.immutable.ArraySeq

class ArraySeqSuite extends CatsSuite {
Expand Down
2 changes: 1 addition & 1 deletion tests/src/test/scala-2.13+/cats/tests/LazyListSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import cats.laws.discipline.{
TraverseTests
}
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.show._
import org.scalatest.funsuite.AnyFunSuiteLike

class LazyListSuite extends CatsSuite {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ import cats.kernel.{Eq, Hash, Order, PartialOrder, Semigroup}
import cats.kernel.laws.discipline.{EqTests, HashTests, OrderTests, PartialOrderTests, SemigroupTests}
import cats.laws.discipline.{AlignTests, BimonadTests, NonEmptyTraverseTests, SemigroupKTests, SerializableTests}
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.either._
import cats.syntax.foldable._

class NonEmptyLazyListSuite extends CatsSuite {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,10 @@ import cats.data.NonEmptyLazyList
import cats.instances.all._
import cats.laws.discipline.{NonEmptyParallelTests, ParallelTests}
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.either._
import cats.syntax.foldable._
import cats.syntax.parallel._
import cats.syntax.traverse._

trait ScalaVersionSpecificFoldableSuite { self: FoldableSuiteAdditional =>
test("Foldable[LazyList].foldM stack safety") {
Expand Down
3 changes: 2 additions & 1 deletion tests/src/test/scala/cats/tests/AlgebraInvariantSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ import cats.laws.discipline.{
import cats.laws.discipline.MiniInt._
import cats.laws.discipline.eq._
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.invariant._
import cats.syntax.order._
import org.scalacheck.{Arbitrary, Gen}

class AlgebraInvariantSuite
Expand Down
4 changes: 3 additions & 1 deletion tests/src/test/scala/cats/tests/ApplicativeErrorSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ import cats.ApplicativeError
import cats.data.EitherT
import cats.instances.all._
import cats.kernel.Eq
import cats.syntax.all._
import cats.syntax.applicativeError._
import cats.syntax.either._
import cats.syntax.option._

class ApplicativeErrorSuite extends CatsSuite {
val failed: Option[Int] =
Expand Down
2 changes: 1 addition & 1 deletion tests/src/test/scala/cats/tests/ApplicativeSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import cats.kernel.Monoid
import cats.kernel.laws.discipline.{MonoidTests, SemigroupTests}
import cats.laws.discipline.arbitrary._
import cats.laws.discipline.{AlignTests, CoflatMapTests}
import cats.syntax.all._
import cats.syntax.applicative._

class ApplicativeSuite extends CatsSuite {

Expand Down
2 changes: 1 addition & 1 deletion tests/src/test/scala/cats/tests/BifoldableSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package cats.tests
import cats.Bifoldable
import cats.instances.all._
import cats.laws.discipline.{BifoldableTests, SerializableTests}
import cats.syntax.all._
import cats.syntax.either._

class BifoldableSuite extends CatsSuite {
type EitherEither[A, B] = Either[Either[A, B], Either[A, B]]
Expand Down
3 changes: 2 additions & 1 deletion tests/src/test/scala/cats/tests/BinestedSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ import cats.instances.all._
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
import cats.laws.discipline.eq._
import cats.syntax.all._
import cats.syntax.bifunctor._
import cats.syntax.binested._

class BinestedSuite extends CatsSuite {
// we have a lot of generated lists of lists in these tests. We have to tell
Expand Down
2 changes: 1 addition & 1 deletion tests/src/test/scala/cats/tests/BitSetSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package cats.tests

import cats.instances.all._
import cats.syntax.all._
import cats.syntax.show._
import org.scalacheck.Arbitrary
import org.scalacheck.Arbitrary.arbitrary
import scala.collection.immutable.BitSet
Expand Down
3 changes: 2 additions & 1 deletion tests/src/test/scala/cats/tests/ChainSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ import cats.laws.discipline.{
TraverseTests
}
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.foldable._
import cats.syntax.semigroup._

class ChainSuite extends CatsSuite {
checkAll("Chain[Int]", AlternativeTests[Chain].alternative[Int, Int, Int])
Expand Down
2 changes: 1 addition & 1 deletion tests/src/test/scala/cats/tests/ComposeSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import cats.kernel.laws.discipline.SemigroupTests
import cats.laws.discipline.{MiniInt, SemigroupKTests, SerializableTests}
import cats.laws.discipline.eq.catsLawsEqForFn1Exhaustive
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.compose._

class ComposeSuite extends CatsSuite {
val functionCompose = Compose[Function1]
Expand Down
2 changes: 1 addition & 1 deletion tests/src/test/scala/cats/tests/ConstSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import cats.kernel.laws.discipline.{
import cats.laws.discipline._
import cats.laws.discipline.SemigroupalTests.Isomorphisms
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.show._
import cats.tests.Helpers.{CMono, CSemi}

class ConstSuite extends CatsSuite {
Expand Down
2 changes: 1 addition & 1 deletion tests/src/test/scala/cats/tests/EitherSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import cats.instances.all._
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
import cats.laws.discipline.SemigroupalTests.Isomorphisms
import cats.syntax.all._
import cats.syntax.either._
import org.scalatest.funsuite.AnyFunSuiteLike
import scala.util.Try

Expand Down
4 changes: 3 additions & 1 deletion tests/src/test/scala/cats/tests/EitherTSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ import cats.kernel.laws.discipline.{EqTests, MonoidTests, OrderTests, PartialOrd
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
import cats.laws.discipline.SemigroupalTests.Isomorphisms
import cats.syntax.all._
import cats.syntax.applicative._
import cats.syntax.applicativeError._
import cats.syntax.either._
import scala.util.{Failure, Success, Try}

class EitherTSuite extends CatsSuite {
Expand Down
8 changes: 7 additions & 1 deletion tests/src/test/scala/cats/tests/FoldableSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,13 @@ import cats.instances.all._
import cats.kernel.{Eq, Monoid}
import cats.kernel.compat.scalaVersionSpecific._
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.alternative._
import cats.syntax.either._
import cats.syntax.foldable._
import cats.syntax.functor._
import cats.syntax.list._
import cats.syntax.reducible._
import cats.syntax.semigroupk._
import org.scalacheck.Arbitrary
import scala.collection.immutable.{SortedMap, SortedSet}
import scala.util.Try
Expand Down
2 changes: 1 addition & 1 deletion tests/src/test/scala/cats/tests/FunctionSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ import cats.laws.discipline._
import cats.laws.discipline.SemigroupalTests.Isomorphisms
import cats.laws.discipline.eq._
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.foldable._
import org.scalacheck.Gen

class FunctionSuite extends CatsSuite {
Expand Down
2 changes: 1 addition & 1 deletion tests/src/test/scala/cats/tests/FunctorSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package cats.tests

import cats.Functor
import cats.instances.all._
import cats.syntax.all._
import cats.syntax.functor._

class FunctorSuite extends CatsSuite {
test("void replaces values with unit preserving structure") {
Expand Down
2 changes: 1 addition & 1 deletion tests/src/test/scala/cats/tests/HashSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package cats.tests
import cats.{Contravariant, Invariant}
import cats.instances.all._
import cats.kernel.Hash
import cats.syntax.all._
import cats.syntax.hash._

class HashSuite extends CatsSuite {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@ import cats.laws.discipline._
import cats.laws.discipline.eq._
import cats.laws.discipline.arbitrary._
import cats.laws.discipline.SemigroupalTests.Isomorphisms
import cats.syntax.all._
import cats.syntax.apply._
import cats.syntax.semigroup._
import cats.syntax.traverse._
import org.scalacheck.Arbitrary

class ReaderWriterStateTSuite extends CatsSuite {
Expand Down
4 changes: 3 additions & 1 deletion tests/src/test/scala/cats/tests/IndexedStateTSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@ import cats.laws.discipline.SemigroupalTests.Isomorphisms
import cats.laws.discipline.eq._
import cats.laws.discipline.arbitrary._
import cats.platform.Platform
import cats.syntax.all._
import cats.syntax.apply._
import cats.syntax.flatMap._
import cats.syntax.traverse._

class IndexedStateTSuite extends CatsSuite {

Expand Down
4 changes: 3 additions & 1 deletion tests/src/test/scala/cats/tests/KleisliSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@ import cats.laws.discipline.arbitrary._
import cats.laws.discipline.eq._
import cats.laws.discipline.SemigroupalTests.Isomorphisms
import cats.laws.discipline.{DeferTests, MonoidKTests, SemigroupKTests}
import cats.syntax.all._
import cats.syntax.flatMap._
import cats.syntax.functor._
import cats.syntax.traverse._
import cats.platform.Platform
import cats.tests.Helpers.CSemi

Expand Down
3 changes: 2 additions & 1 deletion tests/src/test/scala/cats/tests/ListSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ import cats.laws.discipline.{
TraverseTests
}
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.list._
import cats.syntax.show._
import org.scalatest.funsuite.AnyFunSuiteLike

class ListSuite extends CatsSuite {
Expand Down
2 changes: 1 addition & 1 deletion tests/src/test/scala/cats/tests/MapSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import cats.laws.discipline.{
UnorderedTraverseTests
}
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.show._

class MapSuite extends CatsSuite {

Expand Down
3 changes: 2 additions & 1 deletion tests/src/test/scala/cats/tests/MonadErrorSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ package cats.tests

import cats.instances.all._
import cats.kernel.Eq
import cats.syntax.all._
import cats.syntax.applicativeError._
import cats.syntax.monadError._
import scala.util.{Failure, Success, Try}

class MonadErrorSuite extends CatsSuite {
Expand Down
3 changes: 2 additions & 1 deletion tests/src/test/scala/cats/tests/MonadSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ package cats.tests
import cats.{Id, Monad}
import cats.data.{IndexedStateT, StateT}
import cats.instances.all._
import cats.syntax.all._
import cats.syntax.apply._
import cats.syntax.monad._
import org.scalacheck.Gen

class MonadSuite extends CatsSuite {
Expand Down
3 changes: 2 additions & 1 deletion tests/src/test/scala/cats/tests/NonEmptyChainSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ import cats.kernel.{Eq, Order, PartialOrder, Semigroup}
import cats.kernel.laws.discipline.{EqTests, OrderTests, PartialOrderTests, SemigroupTests}
import cats.laws.discipline.{AlignTests, BimonadTests, NonEmptyTraverseTests, SemigroupKTests, SerializableTests}
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.either._
import cats.syntax.foldable._

class NonEmptyChainSuite extends CatsSuite {
checkAll("NonEmptyChain[Int]", SemigroupKTests[NonEmptyChain].semigroupK[Int])
Expand Down
4 changes: 3 additions & 1 deletion tests/src/test/scala/cats/tests/NonEmptyListSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ import cats.laws.discipline.{
SemigroupKTests,
SerializableTests
}
import cats.syntax.all._
import cats.syntax.foldable._
import cats.syntax.reducible._
import cats.syntax.show._
import scala.collection.immutable.{SortedMap, SortedSet}

class NonEmptyListSuite extends CatsSuite {
Expand Down
5 changes: 4 additions & 1 deletion tests/src/test/scala/cats/tests/NonEmptyMapSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,10 @@ import cats.kernel.laws.discipline.{SerializableTests => _, _}
import cats.instances.all._
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.foldable._
import cats.syntax.functor._
import cats.syntax.show._
import cats.syntax.reducible._
import scala.collection.immutable.SortedMap

class NonEmptyMapSuite extends CatsSuite {
Expand Down
4 changes: 3 additions & 1 deletion tests/src/test/scala/cats/tests/NonEmptySetSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ import cats.kernel.{Eq, Order, PartialOrder, Semilattice}
import cats.kernel.laws.discipline.{EqTests, HashTests, OrderTests, SemilatticeTests}
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
import cats.syntax.all._
import cats.syntax.foldable._
import cats.syntax.reducible._
import cats.syntax.show._
import scala.collection.immutable.SortedSet

class NonEmptySetSuite extends CatsSuite {
Expand Down
4 changes: 3 additions & 1 deletion tests/src/test/scala/cats/tests/NonEmptyVectorSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,9 @@ import cats.laws.discipline.{
}
import cats.laws.discipline.arbitrary._
import cats.platform.Platform
import cats.syntax.all._
import cats.syntax.foldable._
import cats.syntax.reducible._
import cats.syntax.show._
import scala.util.Properties

class NonEmptyVectorSuite extends CatsSuite {
Expand Down
2 changes: 1 addition & 1 deletion tests/src/test/scala/cats/tests/OneAndSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import cats.instances.all._
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
import cats.laws.discipline.SemigroupalTests.Isomorphisms
import cats.syntax.all._
import cats.syntax.foldable._

class OneAndSuite extends CatsSuite {
// Lots of collections here.. telling ScalaCheck to calm down a bit
Expand Down
Loading

0 comments on commit 510d139

Please sign in to comment.