@@ -23,21 +23,25 @@ tests = testGroup "data families" [
2323 testProperty " string" (isString . thNullaryToJSONString)
2424 , testProperty " 2ElemArray" (is2ElemArray . thNullaryToJSON2ElemArray)
2525 , testProperty " TaggedObject" (isNullaryTaggedObject . thNullaryToJSONTaggedObject)
26+ , testProperty " TaggedFlatObject" (isNullaryTaggedObject . thNullaryToJSONTaggedFlatObject)
2627 , testProperty " ObjectWithSingleField" (isObjectWithSingleField . thNullaryToJSONObjectWithSingleField)
2728 , testGroup " roundTrip" [
2829 testProperty " string" (toParseJSON thNullaryParseJSONString thNullaryToJSONString)
2930 , testProperty " 2ElemArray" (toParseJSON thNullaryParseJSON2ElemArray thNullaryToJSON2ElemArray)
3031 , testProperty " TaggedObject" (toParseJSON thNullaryParseJSONTaggedObject thNullaryToJSONTaggedObject)
32+ , testProperty " TaggedFlatObject" (toParseJSON thNullaryParseJSONTaggedFlatObject thNullaryToJSONTaggedFlatObject)
3133 , testProperty " ObjectWithSingleField" (toParseJSON thNullaryParseJSONObjectWithSingleField thNullaryToJSONObjectWithSingleField)
3234 ]
3335 ]
3436 , testGroup " SomeType" [
3537 testProperty " 2ElemArray" (is2ElemArray . thSomeTypeToJSON2ElemArray)
3638 , testProperty " TaggedObject" (isTaggedObject . thSomeTypeToJSONTaggedObject)
39+ , testProperty " TaggedFlatObject" (isTaggedObject . thSomeTypeToJSONTaggedFlatObject)
3740 , testProperty " ObjectWithSingleField" (isObjectWithSingleField . thSomeTypeToJSONObjectWithSingleField)
3841 , testGroup " roundTrip" [
3942 testProperty " 2ElemArray" (toParseJSON thSomeTypeParseJSON2ElemArray thSomeTypeToJSON2ElemArray)
4043 , testProperty " TaggedObject" (toParseJSON thSomeTypeParseJSONTaggedObject thSomeTypeToJSONTaggedObject)
44+ , testProperty " TaggedFlatObject" (toParseJSON thSomeTypeParseJSONTaggedFlatObject thSomeTypeToJSONTaggedFlatObject)
4145 , testProperty " ObjectWithSingleField" (toParseJSON thSomeTypeParseJSONObjectWithSingleField thSomeTypeToJSONObjectWithSingleField)
4246 ]
4347 ]
@@ -65,6 +69,8 @@ tests = testGroup "data families" [
6569 thNullaryToJSON2ElemArray `sameAs` thNullaryToEncoding2ElemArray
6670 , testProperty " NullaryTaggedObject" $
6771 thNullaryToJSONTaggedObject `sameAs` thNullaryToEncodingTaggedObject
72+ , testProperty " NullaryTaggedFlatObject" $
73+ thNullaryToJSONTaggedFlatObject `sameAs` thNullaryToEncodingTaggedFlatObject
6874 , testProperty " NullaryObjectWithSingleField" $
6975 thNullaryToJSONObjectWithSingleField `sameAs`
7076 thNullaryToEncodingObjectWithSingleField
@@ -76,6 +82,8 @@ tests = testGroup "data families" [
7682 thSomeTypeToJSON2ElemArray `sameAs` thSomeTypeToEncoding2ElemArray
7783 , testProperty " SomeTypeTaggedObject" $
7884 thSomeTypeToJSONTaggedObject `sameAs` thSomeTypeToEncodingTaggedObject
85+ , testProperty " SomeTypeTaggedFlatObject" $
86+ thSomeTypeToJSONTaggedFlatObject `sameAs` thSomeTypeToEncodingTaggedFlatObject
7987 , testProperty " SomeTypeObjectWithSingleField" $
8088 thSomeTypeToJSONObjectWithSingleField `sameAs`
8189 thSomeTypeToEncodingObjectWithSingleField
@@ -88,21 +96,25 @@ tests = testGroup "data families" [
8896 testProperty " string" (isString . gNullaryToJSONString)
8997 , testProperty " 2ElemArray" (is2ElemArray . gNullaryToJSON2ElemArray)
9098 , testProperty " TaggedObject" (isNullaryTaggedObject . gNullaryToJSONTaggedObject)
99+ , testProperty " TaggedFlatObject" (isNullaryTaggedObject . gNullaryToJSONTaggedFlatObject)
91100 , testProperty " ObjectWithSingleField" (isObjectWithSingleField . gNullaryToJSONObjectWithSingleField)
92101 , testGroup " roundTrip" [
93102 testProperty " string" (toParseJSON gNullaryParseJSONString gNullaryToJSONString)
94103 , testProperty " 2ElemArray" (toParseJSON gNullaryParseJSON2ElemArray gNullaryToJSON2ElemArray)
95104 , testProperty " TaggedObject" (toParseJSON gNullaryParseJSONTaggedObject gNullaryToJSONTaggedObject)
105+ , testProperty " TaggedFlatObject" (toParseJSON gNullaryParseJSONTaggedFlatObject gNullaryToJSONTaggedFlatObject)
96106 , testProperty " ObjectWithSingleField" (toParseJSON gNullaryParseJSONObjectWithSingleField gNullaryToJSONObjectWithSingleField)
97107 ]
98108 ]
99109 , testGroup " SomeType" [
100110 testProperty " 2ElemArray" (is2ElemArray . gSomeTypeToJSON2ElemArray)
101111 , testProperty " TaggedObject" (isTaggedObject . gSomeTypeToJSONTaggedObject)
112+ , testProperty " TaggedFlatObject" (isTaggedObject . gSomeTypeToJSONTaggedFlatObject)
102113 , testProperty " ObjectWithSingleField" (isObjectWithSingleField . gSomeTypeToJSONObjectWithSingleField)
103114 , testGroup " roundTrip" [
104115 testProperty " 2ElemArray" (toParseJSON gSomeTypeParseJSON2ElemArray gSomeTypeToJSON2ElemArray)
105116 , testProperty " TaggedObject" (toParseJSON gSomeTypeParseJSONTaggedObject gSomeTypeToJSONTaggedObject)
117+ , testProperty " TaggedFlatObject" (toParseJSON gSomeTypeParseJSONTaggedFlatObject gSomeTypeToJSONTaggedFlatObject)
106118 , testProperty " ObjectWithSingleField" (toParseJSON gSomeTypeParseJSONObjectWithSingleField gSomeTypeToJSONObjectWithSingleField)
107119 ]
108120 ]
@@ -122,6 +134,8 @@ tests = testGroup "data families" [
122134 gNullaryToJSON2ElemArray `sameAs` gNullaryToEncoding2ElemArray
123135 , testProperty " NullaryTaggedObject" $
124136 gNullaryToJSONTaggedObject `sameAs` gNullaryToEncodingTaggedObject
137+ , testProperty " NullaryTaggedFlatObject" $
138+ gNullaryToJSONTaggedFlatObject `sameAs` gNullaryToEncodingTaggedFlatObject
125139 , testProperty " NullaryObjectWithSingleField" $
126140 gNullaryToJSONObjectWithSingleField `sameAs`
127141 gNullaryToEncodingObjectWithSingleField
@@ -133,6 +147,8 @@ tests = testGroup "data families" [
133147 gSomeTypeToJSON2ElemArray `sameAs` gSomeTypeToEncoding2ElemArray
134148 , testProperty " SomeTypeTaggedObject" $
135149 gSomeTypeToJSONTaggedObject `sameAs` gSomeTypeToEncodingTaggedObject
150+ , testProperty " SomeTypeTaggedFlatObject" $
151+ gSomeTypeToJSONTaggedFlatObject `sameAs` gSomeTypeToEncodingTaggedFlatObject
136152 , testProperty " SomeTypeObjectWithSingleField" $
137153 gSomeTypeToJSONObjectWithSingleField `sameAs`
138154 gSomeTypeToEncodingObjectWithSingleField
0 commit comments