Skip to content

Commit 7882732

Browse files
committed
Simplify test code
1 parent 1e52be8 commit 7882732

File tree

1 file changed

+0
-22
lines changed

1 file changed

+0
-22
lines changed

src/__tests__/ChartTests.js

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -17,52 +17,30 @@ describe('Chart re-rendering', () => {
1717
it('required when data is changed in an inner object/array of the data', () => {
1818
const originalData = {
1919
"data": {
20-
"labels": [
21-
1
22-
],
2320
"datasets": [
2421
{
25-
"label": "a",
26-
"backgroundColor": "#36A2EB",
2722
"data": [
2823
122968
2924
]
3025
},
3126
{
32-
"label": "b",
33-
"backgroundColor": "#FF6384",
3427
"data": [
3528
14738
3629
]
3730
}
3831
]
39-
},
40-
"type": "bar",
41-
"legend": {
42-
"display": true,
43-
"position": "bottom"
4432
}
4533
}
4634
// The new data has only one data set instead of two
4735
const newData = {
4836
"data": {
49-
"labels": [
50-
1
51-
],
5237
"datasets": [
5338
{
54-
"label": "a",
55-
"backgroundColor": "#36A2EB",
5639
"data": [
5740
122968
5841
]
5942
}
6043
]
61-
},
62-
"type": "bar",
63-
"legend": {
64-
"display": true,
65-
"position": "bottom"
6644
}
6745
}
6846
const chart = new ChartComponent(originalData);

0 commit comments

Comments
 (0)