1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37
|
Description: replace ava by tape
Author: Xavier Guimard <yadd@debian.org>
Forwarded: not-needed
Last-Update: 2020-05-30
--- a/test.js
+++ b/test.js
@@ -1,5 +1,5 @@
-import test from 'ava';
-import invertKeyValue from '.';
+const test = require('tape');
+const invertKeyValue = require('.');
test('throws an error if wrong type is given', t => {
t.throws(
@@ -11,6 +11,7 @@
message: 'Expected an object'
}
);
+ t.end();
});
test('inverts string/number properties', t => {
@@ -18,6 +19,7 @@
invertKeyValue({foo: 'bar', unicorn: 'rainbow', 1: 'one'}),
{bar: 'foo', rainbow: 'unicorn', one: '1'}
);
+ t.end();
});
test('inverts symbol properties', t => {
@@ -30,4 +32,5 @@
invertKeyValue({[symbol]: 'foo', rainbow: 'unicorn'}),
{foo: symbol, unicorn: 'rainbow'}
);
+ t.end();
});
|