Added logging, changed some directory structure

This commit is contained in:
2018-01-13 21:33:40 -05:00
parent f079a5f067
commit 8e72ffb917
73656 changed files with 35284 additions and 53718 deletions

View File

@@ -0,0 +1,12 @@
'use strict';
var toArray = require('es5-ext/array/to-array')
, Set = require('../../');
module.exports = function (t, a) {
var content = ['raz', 2, true], set = new Set(content), copy;
copy = t.call(set);
a.not(copy, set, "Copy");
a.deep(toArray(copy), content, "Content");
};

View File

@@ -0,0 +1,9 @@
'use strict';
var Set = require('../../');
module.exports = function (t, a) {
a(t.call(new Set(), Boolean), true, "Empty set");
a(t.call(new Set([2, 3, 4]), Boolean), true, "Truthy");
a(t.call(new Set([2, 0, 4]), Boolean), false, "Falsy");
};

View File

@@ -0,0 +1,12 @@
'use strict';
var aFrom = require('es5-ext/array/from')
, Set = require('../../');
module.exports = function (t, a) {
a.deep(aFrom(t.call(new Set(), Boolean)), [], "Empty set");
a.deep(aFrom(t.call(new Set([2, 3, 4]), Boolean)), [2, 3, 4], "All true");
a.deep(aFrom(t.call(new Set([0, false, 4]), Boolean)), [4], "Some false");
a.deep(aFrom(t.call(new Set([0, false, null]), Boolean)), [], "All false");
};

View File

@@ -0,0 +1,12 @@
'use strict';
var Set = require('../../');
module.exports = function (t, a) {
var content = ['raz', 2, true], set = new Set(content);
a(t.call(set), 'raz');
set = new Set();
a(t.call(set), undefined);
};

View File

@@ -0,0 +1,12 @@
'use strict';
var Set = require('../../');
module.exports = function (t, a) {
var content = ['raz', 2, true], set = new Set(content);
a(t.call(set), true);
set = new Set();
a(t.call(set), undefined);
};

View File

@@ -0,0 +1,10 @@
'use strict';
var Set = require('../../');
module.exports = function (t, a) {
a(t.call(new Set(), Boolean), false, "Empty set");
a(t.call(new Set([2, 3, 4]), Boolean), true, "All true");
a(t.call(new Set([0, false, 4]), Boolean), true, "Some false");
a(t.call(new Set([0, false, null]), Boolean), false, "All false");
};