summaryrefslogtreecommitdiff
path: root/examples/crossBuilds/simple/js/shared/test/scala/simple/SimpleTest.scala
blob: b348c6f48be397612d588e7a4ec92db6ebf8f44f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
/*js/shared/test/scala/simple/SimpleTest.scala*/
/*jvm/shared/test/scala/simple/SimpleTest.scala*/
package simple
import utest._
object SimpleTest extends TestSuite{
  val tests = TestSuite{
    'format{
      'nil - assert(Simple.formatTimes(Nil) == Nil)
      'timeZero - {
        val timestamps = Seq(0L, 1L << 32)
        val expected = Seq(
          "1970-01-01T00:00:00",
          "1970-02-19T17:02:47"
        )
        val formatted = Simple.formatTimes(timestamps)
        assert(formatted == expected)
      }
    }
  }
}