test: helper test fix

This commit is contained in:
Barış Soner Uşaklı
2023-01-11 16:52:25 -05:00
parent b62478bc56
commit 3e7633e791

View File

@@ -77,7 +77,7 @@ describe('helpers', () => {
imageClass: 'auto',
};
const bg = helpers.generateCategoryBackground(category);
assert.equal(bg, 'background-color: #ff0000; color: #00ff00; background-image: url(/assets/uploads/image.png); background-size: auto;');
assert.equal(bg, 'background-color: #ff0000; border-color: #ff0000!important; color: #00ff00; background-image: url(/assets/uploads/image.png); background-size: auto;');
done();
});
@@ -102,7 +102,7 @@ describe('helpers', () => {
],
};
const html = helpers.generateChildrenCategories(category);
assert.equal(html, `<span class="category-children"><span class="category-children-item float-start"><div role="presentation" class="icon float-start" style="background-color: #ff0000; color: #00ff00;"><i class="fa fa-fw undefined"></i></div><a href="${nconf.get('relative_path')}/category/undefined"><small>children</small></a></span></span>`);
assert.equal(html, `<span class="category-children"><span class="category-children-item float-start"><div role="presentation" class="icon float-start" style="background-color: #ff0000; border-color: #ff0000!important; color: #00ff00;"><i class="fa fa-fw undefined"></i></div><a href="${nconf.get('relative_path')}/category/undefined"><small>children</small></a></span></span>`);
done();
});