From f763e8d4e60608a4d99605964d271209fd80cc7f Mon Sep 17 00:00:00 2001 From: kasmine <736929286@qq.com> Date: Sun, 26 Jul 2020 22:02:59 +0800 Subject: [PATCH] =?UTF-8?q?refactor(v2/pie):=20=E4=BF=AE=E6=94=B9=20cr=20?= =?UTF-8?q?=E5=BB=BA=E8=AE=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- __tests__/bugs/issue-1245-spec.ts | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/__tests__/bugs/issue-1245-spec.ts b/__tests__/bugs/issue-1245-spec.ts index 0dac914cb99..875d21c4c8e 100644 --- a/__tests__/bugs/issue-1245-spec.ts +++ b/__tests__/bugs/issue-1245-spec.ts @@ -1,6 +1,5 @@ import { Pie } from '../../src'; import { createDiv } from '.././utils/dom'; -import { delay } from '.././utils/delay'; describe('donut plot', () => { test('angleField & colorField 配置交换, 不会触发 out-of-memory, 但是坐标为 NaN', () => { @@ -90,12 +89,10 @@ describe('donut plot', () => { expect(piePlot).toBeDefined(); expect(piePlot.chart.geometries[0].elements.length).toBe(data.length - 1); - delay(3000).then(() => { - piePlot.update({ - ...piePlot.options, - data: data.map((d, idx) => (idx !== 0 ? { ...d, value: null } : d)), - }); - expect(piePlot.chart.geometries[0].elements.length).toBe(data.length); + piePlot.update({ + ...piePlot.options, + data: data.map((d, idx) => (idx !== 0 ? { ...d, value: null } : d)), }); + expect(piePlot.chart.geometries[0].elements.length).toBe(data.length); }); });