]>
git.argeo.org Git - lgpl/argeo-commons.git/blob - org.argeo.enterprise/ext/test/org/argeo/util/ThroughputTest.java
1 package org
.argeo
.util
;
3 public class ThroughputTest
{
4 public void testParse() throws Exception
{
8 t
= new Throughput("3.54/s");
9 assert 3.54d
== t
.getValue();
10 assert Throughput
.Unit
.s
.equals(t
.getUnit());
11 assert 282l == (long) t
.asMsPeriod();
13 t
= new Throughput("35698.2569/h");
14 assert Throughput
.Unit
.h
.equals(t
.getUnit());
15 assert 101l == (long) t
.asMsPeriod();