Skip to content

Commit

Permalink
Fix test case for client-side JSON enums
Browse files Browse the repository at this point in the history
  • Loading branch information
Tarmil committed Feb 26, 2016
1 parent f26cc16 commit 8f22901
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tests/WebSharper.Web.Tests/ClientSideJson.fs
Original file line number Diff line number Diff line change
Expand Up @@ -280,6 +280,10 @@ module ClientSideJson =
Test "serialize enum" {
equal (Json.Serialize Enum.Case1) "1"
equal (Json.Serialize Enum.Case2) "2"
equal (Json.Serialize (enum<Enum> 3)) "3"
}

Test "deserialize enum" {
equal (Json.Deserialize "1") Enum.Case1
equal (Json.Deserialize "2") Enum.Case2
equal (Json.Deserialize "3") (enum<Enum> 3)
Expand Down

0 comments on commit 8f22901

Please sign in to comment.