This repository has been archived by the owner on May 27, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from circe/topic/encoders-too
Encoders should work too
- Loading branch information
Showing
2 changed files
with
9 additions
and
2 deletions.
There are no files selected for viewing
3 changes: 3 additions & 0 deletions
3
not-java-time/src/main/scala/java/time/temporal/package.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
package java.time.temporal | ||
|
||
trait TemporalAccessor |
8 changes: 6 additions & 2 deletions
8
not-java-time/src/test/scala/io/circe/njt/NotJavaTimeTest.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,14 @@ | ||
package io.circe.njt | ||
|
||
import io.circe.{ Decoder, Json } | ||
import io.circe.{ Decoder, Encoder, Json } | ||
import org.scalatest.FunSuite | ||
|
||
class NotJavaTimeTest extends FunSuite { | ||
test("Using circe should not throw linking errors") { | ||
test("Using Decoder should not throw linking errors") { | ||
assert(Decoder[List[String]].decodeJson(Json.arr()) === Right(Nil)) | ||
} | ||
|
||
test("Using Encoder should not throw linking errors") { | ||
assert(Encoder[List[String]].apply(Nil) === Json.arr()) | ||
} | ||
} |