diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/lib/2.11/contextual-data_2.11-1.1.0.jar | bin | 0 -> 168497 bytes | |||
-rw-r--r-- | tests/lib/2.11/contextual_2.11-1.1.0.jar | bin | 0 -> 57393 bytes | |||
-rw-r--r-- | tests/lib/2.11/estrapade-macros_2.11-1.0.3.jar | bin | 0 -> 32679 bytes | |||
-rw-r--r-- | tests/lib/2.11/estrapade_2.11-1.0.3.jar | bin | 0 -> 109001 bytes | |||
-rw-r--r-- | tests/lib/2.12/contextual-data_2.12-1.1.0.jar | bin | 0 -> 149330 bytes | |||
-rw-r--r-- | tests/lib/2.12/contextual_2.12-1.1.0.jar | bin | 0 -> 48727 bytes | |||
-rw-r--r-- | tests/lib/2.12/estrapade-macros_2.12-1.0.3.jar | bin | 0 -> 26140 bytes | |||
-rw-r--r-- | tests/lib/2.12/estrapade_2.12-1.0.3.jar | bin | 0 -> 79193 bytes | |||
-rw-r--r-- | tests/src/main/scala/tests.scala | 18 |
9 files changed, 10 insertions, 8 deletions
diff --git a/tests/lib/2.11/contextual-data_2.11-1.1.0.jar b/tests/lib/2.11/contextual-data_2.11-1.1.0.jar Binary files differnew file mode 100644 index 0000000..0324473 --- /dev/null +++ b/tests/lib/2.11/contextual-data_2.11-1.1.0.jar diff --git a/tests/lib/2.11/contextual_2.11-1.1.0.jar b/tests/lib/2.11/contextual_2.11-1.1.0.jar Binary files differnew file mode 100644 index 0000000..0f10ba6 --- /dev/null +++ b/tests/lib/2.11/contextual_2.11-1.1.0.jar diff --git a/tests/lib/2.11/estrapade-macros_2.11-1.0.3.jar b/tests/lib/2.11/estrapade-macros_2.11-1.0.3.jar Binary files differnew file mode 100644 index 0000000..3906f72 --- /dev/null +++ b/tests/lib/2.11/estrapade-macros_2.11-1.0.3.jar diff --git a/tests/lib/2.11/estrapade_2.11-1.0.3.jar b/tests/lib/2.11/estrapade_2.11-1.0.3.jar Binary files differnew file mode 100644 index 0000000..d0a3c0b --- /dev/null +++ b/tests/lib/2.11/estrapade_2.11-1.0.3.jar diff --git a/tests/lib/2.12/contextual-data_2.12-1.1.0.jar b/tests/lib/2.12/contextual-data_2.12-1.1.0.jar Binary files differnew file mode 100644 index 0000000..9513196 --- /dev/null +++ b/tests/lib/2.12/contextual-data_2.12-1.1.0.jar diff --git a/tests/lib/2.12/contextual_2.12-1.1.0.jar b/tests/lib/2.12/contextual_2.12-1.1.0.jar Binary files differnew file mode 100644 index 0000000..c0aee69 --- /dev/null +++ b/tests/lib/2.12/contextual_2.12-1.1.0.jar diff --git a/tests/lib/2.12/estrapade-macros_2.12-1.0.3.jar b/tests/lib/2.12/estrapade-macros_2.12-1.0.3.jar Binary files differnew file mode 100644 index 0000000..061da8d --- /dev/null +++ b/tests/lib/2.12/estrapade-macros_2.12-1.0.3.jar diff --git a/tests/lib/2.12/estrapade_2.12-1.0.3.jar b/tests/lib/2.12/estrapade_2.12-1.0.3.jar Binary files differnew file mode 100644 index 0000000..e6a365b --- /dev/null +++ b/tests/lib/2.12/estrapade_2.12-1.0.3.jar diff --git a/tests/src/main/scala/tests.scala b/tests/src/main/scala/tests.scala index 14345af..f79a51b 100644 --- a/tests/src/main/scala/tests.scala +++ b/tests/src/main/scala/tests.scala @@ -27,7 +27,7 @@ case object Blue extends Color object Tests extends TestApp { - def tests() = for(i <- 1 to 1000) { + def tests() = for (i <- 1 to 1000) { import examples._ test("construct a Show product instance") { @@ -39,7 +39,7 @@ object Tests extends TestApp { import examples._ Show.gen[Person].show(Person("John Smith", 34)) }.assert(_ == "Person(name=John Smith,age=34)") - + test("serialize a Branch") { import magnolia.examples._ implicitly[Show[String, Branch[String]]].show(Branch(Leaf("LHS"), Leaf("RHS"))) @@ -70,22 +70,22 @@ object Tests extends TestApp { implicitly[Show[String, Leaf[java.lang.String]]] """ }.assert(_ == Returns(fqt"magnolia.examples.Show[String,magnolia.tests.Leaf[String]]")) - + test("construction of Show instance for Tree") { scalac""" import magnolia.examples._ implicitly[Show[String, Tree[String]]] """ }.assert(_ == Returns(fqt"magnolia.examples.Show[String,magnolia.tests.Tree[String]]")) - + test("serialize a Leaf") { implicitly[Show[String, Leaf[String]]].show(Leaf("testing")) }.assert(_ == "Leaf(value=testing)") - + test("serialize a Branch as a Tree") { implicitly[Show[String, Tree[String]]].show(Branch(Leaf("LHS"), Leaf("RHS"))) }.assert(_ == "Branch(left=Leaf(value=LHS),right=Leaf(value=RHS))") - + test("serialize case object") { implicitly[Show[String, Red.type]].show(Red) }.assert(_ == "Red()") @@ -107,7 +107,9 @@ object Tests extends TestApp { }.assert(_ == Person("John Smith", 32)) test("decode a nested product") { - implicitly[Decoder[Address]].decode("""Address(line1=53 High Street,occupant=Person(name=Richard Jones,age=44))""") + implicitly[Decoder[Address]].decode( + """Address(line1=53 High Street,occupant=Person(name=Richard Jones,age=44))""" + ) }.assert(_ == Address("53 High Street", Person("Richard Jones", 44))) test("show error stack") { @@ -121,6 +123,6 @@ object Tests extends TestApp { | in parameter 'integer' of product type Alpha | in parameter 'alpha' of product type Beta |""")) - + } } |