Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions src/main/scala/stdlib/TypeSignatures.scala
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ object TypeSignatures extends FlatSpec with Matchers with org.scalaexercises.def

/** `isInstanceOf[className]` is used to determine the if an object reference is an instance of given class:
*/
def isInstanceOfFunctionTypeSignatures(res0: Boolean) {
def isInstanceOfFunctionTypeSignatures(res0: Boolean, res1: Boolean, res2: Boolean) {
trait Randomizer[A] {
def draw(): A
}
Expand All @@ -75,7 +75,9 @@ object TypeSignatures extends FlatSpec with Matchers with org.scalaexercises.def
}

val intRand = new IntRandomizer
intRand.draw.isInstanceOf[Int] should be(res0)
intRand.isInstanceOf[IntRandomizer] should be(res0)
intRand.isInstanceOf[Randomizer[Int]] should be(res1)
intRand.draw.isInstanceOf[Int] should be(res2)
}

}
2 changes: 1 addition & 1 deletion src/test/scala/stdlib/TypeSignaturesSpec.scala
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class TypeSignaturesSpec extends Spec with Checkers {
check(
Test.testSuccess(
TypeSignatures.isInstanceOfFunctionTypeSignatures _,
true :: HNil
true :: true :: true :: HNil
)
)
}
Expand Down