2018-10-18 01:27:56 +08:00
|
|
|
// import { acceptance } from "helpers/qunit-helpers";
|
2018-10-17 21:35:32 +08:00
|
|
|
|
2018-10-18 01:27:56 +08:00
|
|
|
// acceptance("Composer - Edit conflict", {
|
|
|
|
// loggedIn: true,
|
2018-10-17 21:35:32 +08:00
|
|
|
|
2018-10-18 01:27:56 +08:00
|
|
|
// pretend(server, helper) {
|
|
|
|
// server.put("/posts/18", () => {
|
|
|
|
// return helper.response(409, { errors: ["edit conflict"] });
|
|
|
|
// });
|
|
|
|
// }
|
|
|
|
// });
|
2018-10-17 21:35:32 +08:00
|
|
|
|
2018-10-18 01:27:56 +08:00
|
|
|
// QUnit.test("Edit a post that causes an edit conflict", async assert => {
|
|
|
|
// await visit("/t/this-is-a-test-topic/9");
|
|
|
|
// await click(".topic-post:eq(0) button.show-more-actions");
|
|
|
|
// await click(".topic-post:eq(0) button.edit");
|
|
|
|
// await click("#reply-control button.create");
|
|
|
|
// assert.equal(
|
|
|
|
// find("#reply-control button.create")
|
|
|
|
// .text()
|
|
|
|
// .trim(),
|
|
|
|
// I18n.t("composer.overwrite_edit"),
|
|
|
|
// "it shows the overwrite button"
|
|
|
|
// );
|
|
|
|
// });
|