Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
"use strict";
const tape = require("tape");
const tapes = require("tapes");
const addAssertions = require("extend-tape");
const sucrose = require("../fixtures/build/sucrose.js");
tape._missing = tape._missing || {};
tape._methods = tape._methods || {};
let _counter = 0;
let _left = 0;
// add a new assertions
const test = addAssertions(tape, {
methods(type, exclusions) {
let instance;
let native = Object.getOwnPropertyNames(new Function());
let common = ["dispatch"];
let excluded = native.concat(common, exclusions);
switch(type) {
case "area":
instance = sucrose.charts.areaChart();
break;
case "bubble":
register(assert, type) {
let name = assert.name.match(/ - ([\w]*):/)[1];
tape._methods[type] = tape._methods[type].filter(function(d) {
return d !== name;
});
},