fix(core): update

This commit is contained in:
2021-10-03 17:37:03 +02:00
parent de87e314c0
commit d4cea26fb5
15 changed files with 194 additions and 130 deletions

View File

@ -11,7 +11,7 @@ tap.test('should sort objects', async () => {
tags: ['city', 'Europe', 'hello'],
timestamp: Date.now(),
featuredImageUrl: null,
url: null
url: null,
},
{
title: 'Washington is a great city',
@ -20,15 +20,15 @@ tap.test('should sort objects', async () => {
tags: ['city', 'USA', 'hello'],
timestamp: Date.now(),
featuredImageUrl: null,
url: null
}
url: null,
},
];
const testArticleSearch = new smartfuzzy.ArticleSearch(articleArray);
const result = await testArticleSearch.search('USA');
console.log(result);
console.log(result[0].matches)
console.log(result[0].matches);
});
tap.start();

View File

@ -11,7 +11,7 @@ tap.test('should sort objects', async () => {
testObjectSorter = new smartfuzzy.ObjectSorter([
new Car('BMW'),
new Car('Mercedes Benz'),
new Car('Volvo')
new Car('Volvo'),
]);
const result = testObjectSorter.sort('Volvo', ['brand']);

View File

@ -8,7 +8,7 @@ tap.test('should create an instance of Smartfuzzy', async () => {
'Sony',
'Deutsche Bahn',
'Apple Inc.',
"Trader Joe's"
"Trader Joe's",
]);
expect(testSmartfuzzy).to.be.instanceof(smartfuzzy.Smartfuzzy);
});