diff options
author | Jon Pretty <jon.pretty@propensive.com> | 2017-10-31 11:11:58 +0100 |
---|---|---|
committer | Jon Pretty <jon.pretty@propensive.com> | 2017-10-31 11:11:58 +0100 |
commit | 88f36a7a552246e210266a7ae82a2e480718512e (patch) | |
tree | 1bce74641f237d081f3d18fc7e5897ecfb2441b8 /tests/src/main/scala/tests.scala | |
parent | 7b776425828d27b3112ad5bddafaa7564c326536 (diff) | |
download | magnolia-88f36a7a552246e210266a7ae82a2e480718512e.tar.gz magnolia-88f36a7a552246e210266a7ae82a2e480718512e.tar.bz2 magnolia-88f36a7a552246e210266a7ae82a2e480718512e.zip |
Support nontrivial type constructors
Diffstat (limited to 'tests/src/main/scala/tests.scala')
-rw-r--r-- | tests/src/main/scala/tests.scala | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/src/main/scala/tests.scala b/tests/src/main/scala/tests.scala index 6bfa1bd..ee3faf0 100644 --- a/tests/src/main/scala/tests.scala +++ b/tests/src/main/scala/tests.scala @@ -27,7 +27,7 @@ object Tests extends TestApp { test("serialize a Branch") { import magnolia.examples._ - implicitly[Show[Branch]].show(Branch(Leaf("LHS"), Leaf("RHS"))) + implicitly[Show[String, Branch]].show(Branch(Leaf("LHS"), Leaf("RHS"))) }.assert(_ == "Branch(left=Leaf(value=LHS),right=Leaf(value=RHS))") test("test equality false") { @@ -52,23 +52,23 @@ object Tests extends TestApp { test("construction of Show instance for Leaf") { scalac""" import magnolia.examples._ - implicitly[Show[Leaf]] + implicitly[Show[String, Leaf]] """ - }.assert(_ == (Returns(fqt"magnolia.examples.Show[magnolia.examples.Leaf]"): Compilation)) + }.assert(_ == (Returns(fqt"magnolia.examples.Show[String,magnolia.examples.Leaf]"): Compilation)) test("construction of Show instance for Tree") { scalac""" import magnolia.examples._ - implicitly[Show[Tree]] + implicitly[Show[String, Tree]] """ - }.assert(_ == (Returns(fqt"magnolia.examples.Show[magnolia.examples.Tree]"): Compilation)) + }.assert(_ == (Returns(fqt"magnolia.examples.Show[String,magnolia.examples.Tree]"): Compilation)) test("serialize a Leaf") { - implicitly[Show[Leaf]].show(Leaf("testing")) + implicitly[Show[String, Leaf]].show(Leaf("testing")) }.assert(_ == "Leaf(value=testing)") test("serialize a Branch as a Tree") { - implicitly[Show[Tree]].show(Branch(Leaf("LHS"), Leaf("RHS"))) + implicitly[Show[String, Tree]].show(Branch(Leaf("LHS"), Leaf("RHS"))) }.assert(_ == "Branch(left=Leaf(value=LHS),right=Leaf(value=RHS))") test("show error stack") { |