All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.specs2.control.NumberOfTimes.scala Maven / Gradle / Ivy

package org.specs2
package control

trait NumberOfTimes {
  /** 
   * This implicit definition allows to declare a number of times
   * `3.times`
   */
  implicit def timesFor(n: Int): Times = new Times(n)
}
trait NoNumberOfTimes extends NumberOfTimes {
  override def timesFor(n: Int): Times = super.timesFor(n)
}
case class Times(n: Int) {
  def times = this
}

object NumberOfTimes extends NumberOfTimes




© 2015 - 2024 Weber Informatics LLC | Privacy Policy