Skip to content

Commit a15e478

Browse files
committed
Separate testdata into two traces
1 parent 89ae294 commit a15e478

File tree

1 file changed

+19
-9
lines changed

1 file changed

+19
-9
lines changed

test/jasmine/tests/bar_test.js

Lines changed: 19 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -903,11 +903,16 @@ describe('A bar plot', function() {
903903

904904
it('Pushes outside text relative bars inside when not outmost', function(done) {
905905
var data = [{
906-
x: [1, 1, 2, 2],
907-
y: [10, 20, 20, 10],
906+
x: [1, 2],
907+
y: [20, 10],
908908
type: 'bar',
909-
text: ['a', 'b', 'c', 'd'],
910-
textposition: ['outside', 'inside', 'outside', 'inside'],
909+
text: ['a', 'b'],
910+
textposition: 'outside',
911+
}, {
912+
x: [1, 2],
913+
y: [20, 10],
914+
type: 'bar',
915+
text: ['c', 'd']
911916
}];
912917
var layout = {barmode: 'relative'};
913918

@@ -934,12 +939,17 @@ describe('A bar plot', function() {
934939

935940
it('does not push text inside when base is set', function(done) {
936941
var data = [{
937-
x: [1, 1, 2, 2],
938-
y: [10, 20, 20, 10],
939-
base: [1, 2, 3, 4],
942+
x: [1, 2],
943+
y: [20, 10],
944+
base: [1, 2],
945+
type: 'bar',
946+
text: ['a', 'b'],
947+
textposition: 'outside',
948+
}, {
949+
x: [3, 4],
950+
y: [30, 40],
940951
type: 'bar',
941-
text: ['a', 'b', 'c', 'd'],
942-
textposition: ['outside', 'outside', 'outside', 'outside'],
952+
text: ['c', 'd']
943953
}];
944954
var layout = {barmode: 'relative'};
945955

0 commit comments

Comments
 (0)