mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-01 03:26:04 +01:00
* fix: display proper site logo or og-image with sizes in head * fix: refactor og:image logic, #7444 - Updated logic to set additional og:image tags based on more factors - logo.png fallback * feat: save image sizes on post upload, re: #7444 * fix: awaiting addTags in topic controller * fix: pass strings to meta tags object * fix: sending absolute image url to meta tag * fix: removed unneeded async and requiring sync db * feat: upgrade to calculate image sizes for all post uploads tracked * fix: tests
This commit is contained in:
@@ -936,7 +936,7 @@ describe('Post\'s', function () {
|
||||
before(function (done) {
|
||||
// Create stub files for testing
|
||||
['abracadabra.png', 'shazam.jpg', 'whoa.gif', 'amazeballs.jpg', 'wut.txt', 'test.bmp']
|
||||
.forEach(filename => fs.closeSync(fs.openSync(path.join(__dirname, '../public/uploads/files', filename), 'w')));
|
||||
.forEach(filename => fs.closeSync(fs.openSync(path.join(nconf.get('upload_path'), 'files', filename), 'w')));
|
||||
|
||||
topics.post({
|
||||
uid: 1,
|
||||
@@ -957,7 +957,7 @@ describe('Post\'s', function () {
|
||||
|
||||
db.sortedSetCard('post:' + pid + ':uploads', function (err, length) {
|
||||
assert.ifError(err);
|
||||
assert.strictEqual(2, length);
|
||||
assert.strictEqual(length, 2);
|
||||
done();
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user