Fixed publish flow related admin tests

This commit is contained in:
Sodbileg Gansukh 2024-09-03 10:35:56 +08:00 committed by Kevin Ansfield
parent cc72d368de
commit 1cee402339
2 changed files with 6 additions and 4 deletions

View File

@ -1,6 +1,6 @@
<div class="modal-content">
<div class="modal-content" data-test-publish-flow="complete">
<header class="modal-header">
<h1>
<h1 data-test-complete-title>
{{#if this.post.isScheduled}}
<span>All set!</span>
{{else}}

View File

@ -115,9 +115,11 @@ describe('Acceptance: Publish flow', function () {
expect(post.status, 'post status after publish').to.equal('published');
expect(find('[data-test-publish-flow="complete"]'), 'complete step').to.exist;
expect(find('[data-test-complete-title]'), 'complete title').to.have.rendered.trimmed.text('Boom. Its out there. Thats 1 post published, keep going!');
expect(find('[data-test-complete-title]'), 'complete title').to.have.rendered.trimmed.text('Boom! It\'s out there.\nThat\'s 1 post published.');
expect(find('[data-test-complete-bookmark]'), 'bookmark card').to.exist;
await visit(`/editor/post/${post.id}`);
// "revert to draft" only shown for scheduled posts
expect(find('[data-test-button="revert-to-draft"]'), 'revert-to-draft button').to.not.exist;
@ -264,7 +266,7 @@ describe('Acceptance: Publish flow', function () {
// complete text has right count
expect(find('[data-test-complete-title]')).to.contain.rendered
.text('Thats 1 post published');
.text('Boom! It\'s out there.\nThat\'s 1 post published.');
});
it('can publish+send with multiple newsletters', async function () {