Skip to content

Commit

Permalink
d3@v6 compatible, change hyphen-minus (U+002D) to `unicode minus (U…
Browse files Browse the repository at this point in the history
…+2212)`
  • Loading branch information
kum-deepak committed Aug 29, 2020
1 parent 59db27a commit 0aaf5a4
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 12 deletions.
12 changes: 6 additions & 6 deletions spec/bar-chart-spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,8 +160,8 @@ describe('dc.BarChart', () => {
});

it('should generate the y-axis domain dynamically', () => {
expect(nthYAxisText(0).text()).toMatch(/-10/);
expect(nthYAxisText(1).text()).toMatch(/-5/);
expect(nthYAxisText(0).text()).toMatch(/10/);
expect(nthYAxisText(1).text()).toMatch(/5/);
expect(nthYAxisText(2).text()).toBe('0');
});

Expand Down Expand Up @@ -583,7 +583,7 @@ describe('dc.BarChart', () => {
return d3.select(chart.selectAll('g.axis.y .tick text').nodes()[n]);
};

expect(nthText(0).text()).toBe('-20');
expect(nthText(0).text()).toBe('20');
expect(nthText(1).text()).toBe('0');
expect(nthText(2).text()).toBe('20');
});
Expand All @@ -609,9 +609,9 @@ describe('dc.BarChart', () => {
return d3.select(chart.selectAll('g.axis.y .tick text').nodes()[n]);
};

expect(nthText(0).text()).toBe('-30');
expect(nthText(1).text()).toBe('-20');
expect(nthText(2).text()).toBe('-10');
expect(nthText(0).text()).toBe('30');
expect(nthText(1).text()).toBe('20');
expect(nthText(2).text()).toBe('10');
expect(nthText(3).text()).toBe('0');
});
});
Expand Down
8 changes: 4 additions & 4 deletions spec/line-chart-spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -562,7 +562,7 @@ describe('dc.lineChart', () => {
return d3.select(chart.selectAll('g.axis.y .tick text').nodes()[n]);
};

expect(nthText(0).text()).toBe('-20');
expect(nthText(0).text()).toBe('20');
expect(nthText(1).text()).toBe('0');
expect(nthText(2).text()).toBe('20');
});
Expand Down Expand Up @@ -598,9 +598,9 @@ describe('dc.lineChart', () => {
return d3.select(chart.selectAll('g.axis.y .tick text').nodes()[n]);
};

expect(nthText(0).text()).toBe('-30');
expect(nthText(1).text()).toBe('-20');
expect(nthText(2).text()).toBe('-10');
expect(nthText(0).text()).toBe('30');
expect(nthText(1).text()).toBe('20');
expect(nthText(2).text()).toBe('10');
expect(nthText(3).text()).toBe('0');
});
});
Expand Down
4 changes: 2 additions & 2 deletions spec/row-chart-spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -460,7 +460,7 @@ describe('dc.rowChart', () => {
}

itShouldBehaveLikeARowChartWithGroup(positiveGroupHolder, 5, ['0', '5', '10']);
itShouldBehaveLikeARowChartWithGroup(negativeGroupHolder, 5, ['-10', '-5', '0']);
itShouldBehaveLikeARowChartWithGroup(mixedGroupHolder, 5, ['-5', '0', '5']);
itShouldBehaveLikeARowChartWithGroup(negativeGroupHolder, 5, ['10', '5', '0']);
itShouldBehaveLikeARowChartWithGroup(mixedGroupHolder, 5, ['5', '0', '5']);
itShouldBehaveLikeARowChartWithGroup(largerGroupHolder, 7);
});

0 comments on commit 0aaf5a4

Please sign in to comment.