-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathChartSeriesSerializationTest.cs
More file actions
36 lines (33 loc) · 988 Bytes
/
Copy pathChartSeriesSerializationTest.cs
File metadata and controls
36 lines (33 loc) · 988 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
using System.Text.Json;
using AppBoxClient.Dynamic;
using NUnit.Framework;
namespace Tests.ClientUI;
public class ChartSeriesSerializationTest
{
[Test]
public void Test1()
{
var json = """
[
{
"Series": "Line",
"Smoothness": null,
"Fill": true,
"DataSource": "orders",
"Field": "Sales",
"Name": null
},
{
"Series": "Line",
"Smoothness": 0,
"Fill": false,
"DataSource": "orders",
"Field": "Amount",
"Name": null
}
]
""";
var res = JsonSerializer.Deserialize(json, typeof(CartesianSeriesSettings[]));
Assert.True(res != null);
}
}