diff options
author | Den Shabalin <den.shabalin@gmail.com> | 2013-12-16 13:59:34 +0100 |
---|---|---|
committer | Den Shabalin <den.shabalin@gmail.com> | 2013-12-16 14:07:45 +0100 |
commit | 71a2102a2df3721e0b8d0a9a5e87d01eb849dadd (patch) | |
tree | 5cc6e93546ec1a2f091865023c9b40738ba0a648 /test/files/scalacheck/si4147.scala | |
parent | b97d44b2d813c1bf482b23efb353e4550818700c (diff) | |
download | scala-71a2102a2df3721e0b8d0a9a5e87d01eb849dadd.tar.gz scala-71a2102a2df3721e0b8d0a9a5e87d01eb849dadd.tar.bz2 scala-71a2102a2df3721e0b8d0a9a5e87d01eb849dadd.zip |
Use t- prefix instead of si- prefix for test files
Diffstat (limited to 'test/files/scalacheck/si4147.scala')
-rw-r--r-- | test/files/scalacheck/si4147.scala | 68 |
1 files changed, 0 insertions, 68 deletions
diff --git a/test/files/scalacheck/si4147.scala b/test/files/scalacheck/si4147.scala deleted file mode 100644 index 72f6e9afd5..0000000000 --- a/test/files/scalacheck/si4147.scala +++ /dev/null @@ -1,68 +0,0 @@ -import org.scalacheck.Prop.{forAll, throws} -import org.scalacheck.Properties -import org.scalacheck.Gen - - -import collection.mutable - - -object Test extends Properties("Mutable TreeSet") { - - val generator = Gen.listOfN(1000, Gen.chooseNum(0, 1000)) - - val denseGenerator = Gen.listOfN(1000, Gen.chooseNum(0, 200)) - - property("Insertion doesn't allow duplicates values.") = forAll(generator) { (s: List[Int]) => - { - val t = mutable.TreeSet[Int](s: _*) - t == s.toSet - } - } - - property("Verification of size method validity") = forAll(generator) { (s: List[Int]) => - { - val t = mutable.TreeSet[Int](s: _*) - for (a <- s) { - t -= a - } - t.size == 0 - } - } - - property("All inserted elements are removed") = forAll(generator) { (s: List[Int]) => - { - val t = mutable.TreeSet[Int](s: _*) - for (a <- s) { - t -= a - } - t == Set() - } - } - - property("Elements are sorted.") = forAll(generator) { (s: List[Int]) => - { - val t = mutable.TreeSet[Int](s: _*) - t.toList == s.distinct.sorted - } - } - - property("Implicit CanBuildFrom resolution succeeds as well as the \"same-result-type\" principle.") = - forAll(generator) { (s: List[Int]) => - { - val t = mutable.TreeSet[Int](s: _*) - val t2 = t.map(_ * 2) - t2.isInstanceOf[collection.mutable.TreeSet[Int]] - } - } - - property("A view doesn't expose off bounds elements") = forAll(denseGenerator) { (s: List[Int]) => - { - val t = mutable.TreeSet[Int](s: _*) - val view = t.rangeImpl(Some(50), Some(150)) - view.filter(_ < 50) == Set[Int]() && view.filter(_ >= 150) == Set[Int]() - } - } - - property("ordering must not be null") = - throws(classOf[NullPointerException])(mutable.TreeSet.empty[Int](null)) -} |