mirror of
https://github.com/chartjs/Chart.js.git
synced 2025-12-08 20:36:08 +00:00
Fix old scaleService tests that are now testing the layoutService
This commit is contained in:
parent
e8f80ca211
commit
29002b2efb
@ -1,5 +1,5 @@
|
||||
// Tests of the scale service
|
||||
describe('Test the scale service', function() {
|
||||
describe('Test the layout service', function() {
|
||||
it('should fit a simple chart with 2 scales', function() {
|
||||
var chartInstance = {
|
||||
scales: [],
|
||||
@ -39,7 +39,7 @@ describe('Test the scale service', function() {
|
||||
|
||||
var canvasWidth = 250;
|
||||
var canvasHeight = 150;
|
||||
Chart.scaleService.update(chartInstance, canvasWidth, canvasHeight);
|
||||
Chart.layoutService.update(chartInstance, canvasWidth, canvasHeight);
|
||||
|
||||
expect(chartInstance.chartArea).toEqual({
|
||||
left: 45,
|
||||
@ -103,7 +103,7 @@ describe('Test the scale service', function() {
|
||||
|
||||
var canvasWidth = 250;
|
||||
var canvasHeight = 150;
|
||||
Chart.scaleService.update(chartInstance, canvasWidth, canvasHeight);
|
||||
Chart.layoutService.update(chartInstance, canvasWidth, canvasHeight);
|
||||
|
||||
expect(chartInstance.chartArea).toEqual({
|
||||
left: 5,
|
||||
@ -176,7 +176,7 @@ describe('Test the scale service', function() {
|
||||
|
||||
var canvasWidth = 250;
|
||||
var canvasHeight = 150;
|
||||
Chart.scaleService.update(chartInstance, canvasWidth, canvasHeight);
|
||||
Chart.layoutService.update(chartInstance, canvasWidth, canvasHeight);
|
||||
|
||||
expect(chartInstance.chartArea).toEqual({
|
||||
left: 95,
|
||||
@ -238,7 +238,7 @@ describe('Test the scale service', function() {
|
||||
|
||||
var canvasWidth = 300;
|
||||
var canvasHeight = 350;
|
||||
Chart.scaleService.update(chartInstance, canvasWidth, canvasHeight);
|
||||
Chart.layoutService.update(chartInstance, canvasWidth, canvasHeight);
|
||||
|
||||
expect(chartInstance.chartArea).toEqual({
|
||||
left: 5,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user