Fixed dynamic routing test suite

refs https://github.com/TryGhost/Toolbox/issues/230

- Code tweaks to make test suite play nicely without single post author concept
This commit is contained in:
Naz 2022-04-27 19:53:07 +08:00 committed by naz
parent e38c8a4662
commit 30de0603ca

View File

@ -279,7 +279,9 @@ describe('Dynamic Routing', function () {
}).then(function (insertedUser) {
return testUtils.fixtures.insertPosts([
testUtils.DataGenerator.forKnex.createPost({
author_id: insertedUser.id
authors: [{
id: insertedUser.id
}]
})
]);
}).then(function () {
@ -287,7 +289,9 @@ describe('Dynamic Routing', function () {
}).then(function (insertedUser) {
return testUtils.fixtures.insertPosts([
testUtils.DataGenerator.forKnex.createPost({
author_id: insertedUser.id
authors: [{
id: insertedUser.id
}]
})
]);
}).then(() => {
@ -295,7 +299,9 @@ describe('Dynamic Routing', function () {
}).then(function (insertedUser) {
return testUtils.fixtures.insertPosts([
testUtils.DataGenerator.forKnex.createPost({
author_id: insertedUser.id
authors: [{
id: insertedUser.id
}]
})
]);
}).then(function () {