mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-03-11 02:12:21 -05:00
Change tests to accommodate pg differences.
Refs #2499 - Since PostgreSQL handles transactions differently than MySQL and SQLite3 there are differences in the way and number of errors that are returned. Update tests to only check that at least one error of the proper type was returned.
This commit is contained in:
parent
3a1839dfa3
commit
74fd6fc09a
1 changed files with 1 additions and 12 deletions
|
@ -606,19 +606,8 @@ describe('Import', function () {
|
|||
}).then(function () {
|
||||
done(new Error('Allowed import of duplicate data'));
|
||||
}).catch(function (response) {
|
||||
response.length.should.equal(3);
|
||||
response.length.should.be.above(0);
|
||||
response[0].type.should.equal('DataImportError');
|
||||
response[0].message.should.eql(
|
||||
'Duplicate entry found. Multiple values of "tagging-things" found for tags.slug.'
|
||||
);
|
||||
response[1].type.should.equal('DataImportError');
|
||||
response[1].message.should.eql(
|
||||
'Duplicate entry found. Multiple values of "tagging-things" found for tags.slug.'
|
||||
);
|
||||
response[2].type.should.equal('DataImportError');
|
||||
response[2].message.should.eql(
|
||||
'Duplicate entry found. Multiple values of "test-ghost-post" found for posts.slug.'
|
||||
);
|
||||
done();
|
||||
}).catch(done);
|
||||
});
|
||||
|
|
Loading…
Add table
Reference in a new issue