@@ -1321,7 +1321,15 @@ describe('filter transforms interactions', function() {
1321
1321
} ) ;
1322
1322
1323
1323
describe ( 'filter resulting in empty coordinate arrays' , function ( ) {
1324
- afterEach ( destroyGraphDiv ) ;
1324
+ var gd ;
1325
+
1326
+ afterEach ( function ( done ) {
1327
+ Plotly . purge ( gd ) ;
1328
+ setTimeout ( function ( ) {
1329
+ destroyGraphDiv ( ) ;
1330
+ done ( ) ;
1331
+ } , 200 ) ;
1332
+ } ) ;
1325
1333
1326
1334
function filter2empty ( mock ) {
1327
1335
var fig = Lib . extendDeep ( { } , mock ) ;
@@ -1348,7 +1356,7 @@ describe('filter resulting in empty coordinate arrays', function() {
1348
1356
}
1349
1357
1350
1358
it ( d [ 0 ] , function ( done ) {
1351
- var gd = createGraphDiv ( ) ;
1359
+ gd = createGraphDiv ( ) ;
1352
1360
var fig = filter2empty ( d [ 1 ] ) ;
1353
1361
Plotly . newPlot ( gd , fig ) . catch ( failTest ) . then ( done ) ;
1354
1362
} ) ;
@@ -1360,7 +1368,7 @@ describe('filter resulting in empty coordinate arrays', function() {
1360
1368
1361
1369
mockList . forEach ( function ( d ) {
1362
1370
it ( '@gl ' + d [ 0 ] , function ( done ) {
1363
- var gd = createGraphDiv ( ) ;
1371
+ gd = createGraphDiv ( ) ;
1364
1372
var fig = filter2empty ( d [ 1 ] ) ;
1365
1373
Plotly . newPlot ( gd , fig ) . catch ( failTest ) . then ( done ) ;
1366
1374
} ) ;
@@ -1376,7 +1384,7 @@ describe('filter resulting in empty coordinate arrays', function() {
1376
1384
1377
1385
mockList . forEach ( function ( d ) {
1378
1386
it ( '@noCI ' + d [ 0 ] , function ( done ) {
1379
- var gd = createGraphDiv ( ) ;
1387
+ gd = createGraphDiv ( ) ;
1380
1388
var fig = filter2empty ( d [ 1 ] ) ;
1381
1389
Plotly . newPlot ( gd , fig ) . catch ( failTest ) . then ( done ) ;
1382
1390
} ) ;
0 commit comments