Skip to content

Commit 869367e

Browse files
committed
Fix failing test
1 parent 05e851f commit 869367e

1 file changed

Lines changed: 21 additions & 16 deletions

File tree

test/jasmine/tests/scatter_marker_line_dash_test.js

Lines changed: 21 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -63,23 +63,28 @@ describe('Test scatter marker line dash:', function() {
6363
});
6464

6565
it('should show marker line dash in the legend', function(done) {
66-
Plotly.newPlot(gd, [{
67-
mode: 'markers',
68-
x: [1, 2, 3],
69-
y: [1, 2, 3],
70-
marker: {
71-
line: {
72-
color: 'red',
73-
width: 2,
74-
dash: 'dash'
66+
Plotly.newPlot(
67+
gd,
68+
[{
69+
mode: 'markers',
70+
x: [1, 2, 3],
71+
y: [1, 2, 3],
72+
marker: {
73+
line: {
74+
color: 'red',
75+
width: 2,
76+
dash: 'dash'
77+
}
7578
}
76-
}
77-
}]).then(function() {
78-
var legendPoints = gd.querySelectorAll('.legendpoints path.point');
79-
expect(legendPoints.length).toBe(1);
80-
expect(legendPoints[0].style.strokeDasharray).not.toBe('');
81-
})
82-
.then(done, done.fail);
79+
}],
80+
{ showlegend: true }
81+
)
82+
.then(function () {
83+
var legendPoints = gd.querySelectorAll('.legendpoints path.scatterpts');
84+
expect(legendPoints.length).toBe(1);
85+
expect(legendPoints[0].style.strokeDasharray).not.toBe('');
86+
})
87+
.then(done, done.fail);
8388
});
8489

8590
it('should update marker line dash via restyle', function(done) {

0 commit comments

Comments
 (0)