Revision 92f5e0d5 src/test/scala/gr/grnet/aquarium/logic/test/PerfTest.scala
b/src/test/scala/gr/grnet/aquarium/logic/test/PerfTest.scala | ||
---|---|---|
36 | 36 |
package gr.grnet.aquarium.logic.test |
37 | 37 |
|
38 | 38 |
import org.junit.Test |
39 |
import gr.grnet.aquarium.logic.accounting.dsl.{DSLTimeFrame, DSLTimeFrameRepeat, DSL, DSLUtils} |
|
40 | 39 |
import java.util.{Date} |
41 | 40 |
import org.junit.Assume._ |
42 | 41 |
import gr.grnet.aquarium.LogicTestsAssumptions |
42 |
import gr.grnet.aquarium.logic.accounting.dsl._ |
|
43 | 43 |
|
44 | 44 |
/** |
45 | 45 |
* Performance tests for various critical path functions. |
... | ... | |
82 | 82 |
while (rndEnd.before(rndStart)) rndEnd = new Date((min + (scala.math.random * (max - min) + 1)).toLong) |
83 | 83 |
val tf = DSLTimeFrame(rndStart, Some(rndEnd), List(repeat1, repeat2)) |
84 | 84 |
|
85 |
numResolved += allEffectiveTimeslots(tf, new Date(min), new Date(max)).size
|
|
85 |
numResolved += allEffectiveTimeslots(tf, Timeslot(new Date(min), new Date(max))).size
|
|
86 | 86 |
} |
87 | 87 |
|
88 | 88 |
var total = System.currentTimeMillis() - start |
Also available in: Unified diff