Skip to content

Commit 48860c2

Browse files
committed
fixup tests to run on CI
1 parent ebf57f0 commit 48860c2

File tree

3 files changed

+38
-38
lines changed

3 files changed

+38
-38
lines changed
Loading

test/image/mocks/gl2d_parcoords_style_labels.json

Lines changed: 31 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,37 @@
1919
},
2020
"dimensions": [
2121
{
22-
"label": "$\\varphi ={\\frac {1+{\\sqrt {5}}}{2}}$",
22+
"label": "<i>Rien ne se perd,<br>rien ne se crée,<br>tout se <b>transforme</b>.</i><sub>",
23+
"values": [
24+
1,
25+
2,
26+
3,
27+
5,
28+
8,
29+
13
30+
],
31+
"range": [
32+
0,
33+
20
34+
]
35+
},
36+
{
37+
"label": "<b>e<sup>iπ</sup> = cos i + i sin π</b>",
38+
"values": [
39+
-1,
40+
-1,
41+
-1,
42+
-1,
43+
-1,
44+
-1
45+
],
46+
"range": [
47+
1,
48+
-1
49+
]
50+
},
51+
{
52+
"label": "<i>Golden ratio</i><br>1.618",
2353
"values": [
2454
1,
2555
2,
@@ -48,36 +78,6 @@
4878
1.55,
4979
1.7
5080
]
51-
},
52-
{
53-
"label": "<b>e<sup>iπ</sup> = cos i + i sin π</b>",
54-
"values": [
55-
-1,
56-
-1,
57-
-1,
58-
-1,
59-
-1,
60-
-1
61-
],
62-
"range": [
63-
1,
64-
-1
65-
]
66-
},
67-
{
68-
"label": "<i>Rien ne se perd,<br>rien ne se crée,<br>tout se <b>transforme</b>.</i><sub>",
69-
"values": [
70-
1,
71-
2,
72-
3,
73-
5,
74-
8,
75-
13
76-
],
77-
"range": [
78-
0,
79-
20
80-
]
8181
}
8282
]
8383
}

test/jasmine/tests/parcoords_test.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1180,17 +1180,17 @@ describe('parcoords react more attributes', function() {
11801180
m0.labelfont = { size: '24', family: 'Times', color: 'orange' };
11811181
m0.rangefont = { size: '20', family: 'Times', color: 'brown' };
11821182
m0.tickfont = { size: '16', family: 'Times', color: 'yellow' };
1183-
m0.dimensions[2].label = 'Changed!';
1183+
m0.dimensions[0].label = 'Changed!';
11841184
m0.dimensions[1].range = ['-2', '2'];
1185-
m0.dimensions[0].constraintrange = [];
1185+
m0.dimensions[2].constraintrange = [];
11861186
m0.dimensions[1].multiselect = false;
11871187
m0.dimensions[1].constraintrange = [
11881188
[-1.5, -0.5],
11891189
[0, 1.5] // won't be selected because multiselect is tuned off.
11901190
];
1191-
m0.dimensions[2].constraintrange = [[2, 4], [7, 10], [11, 12]];
1192-
m0.dimensions[2].tickvals = ['1', '2', '3', '5', '8', '13'];
1193-
m0.dimensions[2].ticktext = ['1/1', '2/1', '3/2', '5/3', '8/5', '13/8'];
1191+
m0.dimensions[0].constraintrange = [[2, 4], [7, 10], [11, 12]];
1192+
m0.dimensions[0].tickvals = ['1', '2', '3', '5', '8', '13'];
1193+
m0.dimensions[0].ticktext = ['1/1', '2/1', '3/2', '5/3', '8/5', '13/8'];
11941194
m0.domain = { x: [0, 0.5], y: [0, 0.5] };
11951195

11961196
Plotly.react(gd, mockCopy.data).then(function() {
@@ -1246,9 +1246,9 @@ describe('parcoords react more attributes', function() {
12461246
highlight.getAttribute('stroke-dasharray').split(',').length
12471247
);
12481248
});
1249-
expect(nHighlight[0]).toBe(2);
1250-
expect(nHighlight[1]).toBe(4);
12511249
expect(nHighlight[2]).toBe(6);
1250+
expect(nHighlight[1]).toBe(2);
1251+
expect(nHighlight[0]).toBe(4);
12521252
})
12531253
.catch(failTest)
12541254
.then(done);

0 commit comments

Comments
 (0)