diff options
author | stuebinm | 2021-04-26 11:44:44 +0200 |
---|---|---|
committer | stuebinm | 2021-04-26 11:44:44 +0200 |
commit | 033391a6b4a9f6150a0054db0869246c1f46357b (patch) | |
tree | 55413151f95f1406242e727a64f222b1d72ad1ad /serde_dhall/tests | |
parent | 449d72e98e427b3f81dc72e800098fce8895353b (diff) |
derive macro: add test for record in sum typederive-macro
Diffstat (limited to 'serde_dhall/tests')
-rw-r--r-- | serde_dhall/tests/traits.rs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/serde_dhall/tests/traits.rs b/serde_dhall/tests/traits.rs index ed768c1..cd29f9e 100644 --- a/serde_dhall/tests/traits.rs +++ b/serde_dhall/tests/traits.rs @@ -64,4 +64,14 @@ fn test_static_type() { B(bool), } assert_eq!(F::static_type(), parse("< A | B: Bool >")); + + + #[derive(StaticType)] + #[allow(dead_code)] + enum G { + A, + B(bool), + C {a: bool, b: u64} + } + assert_eq!(G::static_type(), parse("< A | B: Bool | C: { a: Bool, b: Natural } >")) } |