Skip to content

Commit

Permalink
Remove cats.instances from tests (#3378)
Browse files Browse the repository at this point in the history
* Remove cats.instances from tests
  • Loading branch information
travisbrown authored Apr 1, 2020
1 parent dbf84cd commit 424569f
Show file tree
Hide file tree
Showing 87 changed files with 2 additions and 99 deletions.
1 change: 0 additions & 1 deletion tests/src/test/scala-2.13+/cats/tests/ArraySeqSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.{Align, Alternative, CoflatMap, Monad, MonoidK, Traverse, TraverseFilter}
import cats.instances.all._
import cats.kernel.{Eq, Hash, Monoid, Order, PartialOrder}
import cats.kernel.laws.discipline.{EqTests, HashTests, MonoidTests, OrderTests, PartialOrderTests}
import cats.laws.discipline.{
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala-2.13+/cats/tests/LazyListSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cats.tests

import cats.{Align, Alternative, CoflatMap, Monad, Semigroupal, Traverse, TraverseFilter}
import cats.data.ZipLazyList
import cats.instances.all._
import cats.laws.discipline.{
AlignTests,
AlternativeTests,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cats.tests

import cats.{Align, Bimonad, SemigroupK, Show, Traverse}
import cats.data.{NonEmptyLazyList, NonEmptyLazyListOps}
import cats.instances.all._
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}
Expand Down
12 changes: 1 addition & 11 deletions tests/src/test/scala/cats/tests/AlgebraInvariantSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.{CommutativeApplicative, CommutativeApply, Invariant, InvariantMonoidal}
import cats.instances._
import cats.kernel._
import cats.kernel.laws.discipline.{SemigroupTests, MonoidTests, GroupTests, _}
import cats.laws.discipline.{
Expand All @@ -18,16 +17,7 @@ import cats.syntax.invariant._
import cats.syntax.order._
import org.scalacheck.{Arbitrary, Gen}

class AlgebraInvariantSuite
extends CatsSuite
with AllInstances
with AllInstancesBinCompat0
with AllInstancesBinCompat1
with AllInstancesBinCompat2
with AllInstancesBinCompat3
with AllInstancesBinCompat4
with AllInstancesBinCompat5
with AllInstancesBinCompat6 {
class AlgebraInvariantSuite extends CatsSuite {
// working around https://github.com/typelevel/cats/issues/2701
implicit private val eqSetBooleanTuple: Eq[(Set[Boolean], Set[Boolean])] = Eq.fromUniversalEquals
implicit private val eqSetBooleanBooleanTuple: Eq[(Set[Boolean], Boolean)] = Eq.fromUniversalEquals
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/AlignSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.Align
import cats.instances.all._
import cats.kernel.laws.discipline.SemigroupTests

class AlignSuite extends CatsSuite {
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/AlternativeSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.Alternative
import cats.instances.all._

class AlternativeSuite extends CatsSuite {
test("unite") {
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/AndThenSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package cats.tests
import cats.{Contravariant, ContravariantMonoidal, Monad, Semigroupal}
import cats.arrow.{ArrowChoice, Choice, CommutativeArrow}
import cats.data.AndThen
import cats.instances.all._
import cats.kernel.laws.discipline.SerializableTests
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cats.tests

import cats.ApplicativeError
import cats.data.EitherT
import cats.instances.all._
import cats.kernel.Eq
import cats.syntax.applicativeError._
import cats.syntax.either._
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/ApplicativeSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cats.tests

import cats.{Align, Applicative, Apply, CoflatMap}
import cats.data.{Const, Validated}
import cats.instances.all._
import cats.kernel.Monoid
import cats.kernel.laws.discipline.{MonoidTests, SemigroupTests}
import cats.laws.discipline.arbitrary._
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/BifoldableSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.Bifoldable
import cats.instances.all._
import cats.laws.discipline.{BifoldableTests, SerializableTests}
import cats.syntax.either._

Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/BifunctorSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.{Bifunctor, Functor}
import cats.instances.all._
import cats.laws.discipline.{BifunctorTests, FunctorTests, SerializableTests}

class BifunctorSuite extends CatsSuite {
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/BinestedSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import cats.{Bifoldable, Bifunctor, Bitraverse, Foldable, Functor, Traverse}
import cats.arrow.Profunctor
import cats.data.Binested
import cats.kernel.Eq
import cats.instances.all._
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
import cats.laws.discipline.eq._
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/BitSetSuite.scala
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package cats.tests

import cats.instances.all._
import cats.syntax.show._
import org.scalacheck.Arbitrary
import org.scalacheck.Arbitrary.arbitrary
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/BitraverseSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.Bitraverse
import cats.instances.all._
import cats.laws.discipline.{BitraverseTests, SerializableTests}

class BitraverseSuite extends CatsSuite {
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/CategorySuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cats.tests

import cats.Endo
import cats.arrow.Category
import cats.instances.all._
import cats.kernel.laws.discipline.MonoidTests
import cats.laws.discipline.{MiniInt, MonoidKTests, SerializableTests}
import cats.laws.discipline.eq.catsLawsEqForFn1Exhaustive
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/ChainSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import cats.{Align, Alternative, CoflatMap, Monad, Show, Traverse, TraverseFilte
import cats.data.Chain
import cats.data.Chain.==:
import cats.data.Chain.`:==`
import cats.instances.all._
import cats.kernel.{Eq, Hash, Monoid, Order, PartialOrder}
import cats.kernel.laws.discipline.{EqTests, HashTests, MonoidTests, OrderTests, PartialOrderTests}
import cats.laws.discipline.{
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/CokleisliSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package cats.tests
import cats.{Contravariant, Id, Monad, MonoidK, SemigroupK, Semigroupal}
import cats.arrow._
import cats.data.{Cokleisli, NonEmptyList}
import cats.instances.all._
import cats.kernel.Eq
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/ComposeSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cats.tests

import cats.Endo
import cats.arrow.Compose
import cats.instances.all._
import cats.kernel.laws.discipline.SemigroupTests
import cats.laws.discipline.{MiniInt, SemigroupKTests, SerializableTests}
import cats.laws.discipline.eq.catsLawsEqForFn1Exhaustive
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/ConstSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cats.tests

import cats._
import cats.data.{Const, NonEmptyList}
import cats.instances.all._
import cats.kernel.Semigroup
import cats.kernel.laws.discipline.{
EqTests,
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/ContTSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cats.tests

import cats.Eval
import cats.data.ContT
import cats.instances.all._
import cats.kernel.Eq
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/ContravariantSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cats.tests

import cats.{Contravariant, ContravariantMonoidal, ContravariantSemigroupal}
import cats.data.Const
import cats.instances.all._
import cats.kernel.{Eq, Monoid, Semigroup}
import cats.kernel.laws.discipline.{MonoidTests, SemigroupTests}
import cats.laws.discipline.{ContravariantMonoidalTests, ExhaustiveCheck, MiniInt}
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/DurationSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.Show
import cats.instances.all._
import cats.laws.discipline.SerializableTests
import scala.concurrent.duration.{Duration, DurationInt}

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

import cats._
import cats.data.EitherK
import cats.instances.all._
import cats.kernel.laws.discipline.EqTests
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
Expand Down
2 changes: 0 additions & 2 deletions tests/src/test/scala/cats/tests/EitherSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package cats.tests
import cats._
import cats.data.{EitherT, NonEmptyChain, NonEmptyList, NonEmptySet, Validated}
import cats.kernel.laws.discipline.{EqTests, MonoidTests, OrderTests, PartialOrderTests, SemigroupTests}
import cats.instances.all._
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
import cats.laws.discipline.SemigroupalTests.Isomorphisms
Expand Down Expand Up @@ -375,7 +374,6 @@ final class EitherInstancesSuite extends AnyFunSuiteLike {

test("parallel instance in cats.instances.either") {
import cats.instances.either._
import cats.instances.string._
import cats.syntax.parallel._

def either: Either[String, Int] = Left("Test")
Expand Down
3 changes: 1 addition & 2 deletions tests/src/test/scala/cats/tests/EitherTSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cats.tests

import cats._
import cats.data.{EitherT, State}
import cats.instances.all._
import cats.kernel.laws.discipline.{EqTests, MonoidTests, OrderTests, PartialOrderTests, SemigroupTests}
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
Expand Down Expand Up @@ -90,7 +89,7 @@ class EitherTSuite extends CatsSuite {
implicit val eq2: Eq[EitherT[EitherT[Option, String, *], Unit, String]] =
EitherT.catsDataEqForEitherT[EitherT[Option, String, *], Unit, String](eq1)
implicit val me: MonadError[EitherT[Option, String, *], Unit] =
EitherT.catsDataMonadErrorFForEitherT[Option, Unit, String](catsStdInstancesForOption)
EitherT.catsDataMonadErrorFForEitherT[Option, Unit, String](cats.instances.option.catsStdInstancesForOption)

Functor[EitherT[Option, String, *]]
Applicative[EitherT[Option, String, *]]
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/EqSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.{Contravariant, ContravariantMonoidal, ContravariantSemigroupal, Invariant, Semigroupal}
import cats.instances.all._
import cats.kernel.Eq
import cats.kernel.laws.discipline.SerializableTests
import cats.laws.discipline.{ContravariantMonoidalTests, MiniInt}
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/EquivSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.{Contravariant, ContravariantMonoidal, ContravariantSemigroupal, Invariant, Semigroupal}
import cats.instances.all._
import cats.laws.discipline.arbitrary._
import cats.laws.discipline._
import cats.laws.discipline.eq._
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/EvalSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.{Bimonad, CommutativeMonad, Eval, Reducible}
import cats.instances.all._
import cats.laws.ComonadLaws
import cats.laws.discipline.{
BimonadTests,
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/ExtraRegressionSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.Show
import cats.instances.all._
import ExtraRegressionSuite._

class ExtraRegressionSuite extends CatsSuite {
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/FiniteDurationSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.Show
import cats.instances.all._
import cats.laws.discipline.SerializableTests
import scala.concurrent.duration.{DurationInt, FiniteDuration}

Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/FuncSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package cats.tests
import cats.{Applicative, Apply, Contravariant, Functor, Semigroupal, Show}
import cats.data.{AppFunc, Func}
import cats.data.Func.appFunc
import cats.instances.all._
import cats.kernel.Eq
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/FunctionKSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import cats.Id
import cats.arrow.FunctionK
import cats.data.EitherK
import cats.data.NonEmptyList
import cats.instances.all._
import cats.laws.discipline.arbitrary._

class FunctionKSuite extends CatsSuite {
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/FunctionSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import cats.{
Semigroupal
}
import cats.arrow.{ArrowChoice, Choice, CommutativeArrow}
import cats.instances.all._
import cats.kernel._
import cats.kernel.laws.HashLaws
import cats.kernel.laws.discipline.{
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/FunctorSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

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

class FunctorSuite extends CatsSuite {
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/GroupSuite.scala
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package cats.tests

import cats.instances.all._
import cats.kernel.Group
import cats.kernel.laws.discipline.GroupTests

Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/HashSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.{Contravariant, Invariant}
import cats.instances.all._
import cats.kernel.Hash
import cats.syntax.hash._

Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/IdSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.{Bimonad, CommutativeMonad, Id, Reducible, Traverse}
import cats.instances.all._
import cats.laws.discipline._

class IdSuite extends CatsSuite {
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/IdTSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cats.tests

import cats._
import cats.data.{Const, IdT, NonEmptyList}
import cats.instances.all._
import cats.kernel.laws.discipline.{EqTests, OrderTests}
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package cats.tests
import cats.{~>, Bifunctor, Contravariant, Eval, Functor, Id, Monad, MonadError, SemigroupK}
import cats.arrow.{Profunctor, Strong}
import cats.data.{EitherT, IRWST, IndexedReaderWriterStateT, ReaderWriterState, ReaderWriterStateT}
import cats.instances.all._
import cats.kernel.{Eq, Monoid}
import cats.laws.discipline._
import cats.laws.discipline.eq._
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/InjectKSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package cats.tests
import cats.{:<:, Functor, InjectK}
import cats.data.EitherK
import cats.kernel.Eq
import cats.instances.all._
import cats.laws.discipline.InjectKTests
import org.scalacheck._

Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/InjectSuite.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.Inject
import cats.instances.all._
import cats.laws.discipline.InjectTests

class InjectSuite extends CatsSuite {
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/IorSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cats.tests

import cats.{Bitraverse, MonadError, Semigroupal, Show, Traverse}
import cats.data.{EitherT, Ior, NonEmptyChain, NonEmptyList, NonEmptySet}
import cats.instances.all._
import cats.kernel.{Eq, Semigroup}
import cats.kernel.laws.discipline.SemigroupTests
import cats.laws.discipline.{
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/IorTSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package cats.tests

import cats.{~>, Bifunctor, Eval, Foldable, Functor, Id, Monad, MonadError, Traverse}
import cats.data.{Ior, IorT}
import cats.instances.all._
import cats.kernel.{Eq, Monoid, Semigroup}
import cats.kernel.laws.discipline.{EqTests, MonoidTests, SemigroupTests}
import cats.laws.discipline._
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package cats.tests

import cats.{Contravariant, ContravariantSemigroupal, Invariant, Semigroupal}
import cats.instances.all._
import cats.kernel.{Eq, Hash, Order, PartialOrder}
import cats.laws.discipline.arbitrary._
import cats.laws.discipline._
Expand Down
1 change: 0 additions & 1 deletion tests/src/test/scala/cats/tests/KleisliSuite.scala
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package cats.tests
import cats._
import cats.arrow._
import cats.data.{Const, EitherT, Kleisli, Reader, ReaderT}
import cats.instances.all._
import cats.kernel.laws.discipline.{MonoidTests, SemigroupTests}
import cats.laws.discipline._
import cats.laws.discipline.arbitrary._
Expand Down
Loading

0 comments on commit 424569f

Please sign in to comment.