MCPcopy Create free account
hub / github.com/decaporg/decap-cms / createPostPublishAndCreateNew

Function createPostPublishAndCreateNew

cypress/utils/steps.js:345–354  ·  view source on GitHub ↗
(entry)

Source from the content-addressed store, hash-verified

343}
344
345function createPostPublishAndCreateNew(entry) {
346 newPost();
347 populateEntry(entry, () => publishEntry({ createNew: true }));
348 cy.url().should('eq', `http://localhost:8080/#/collections/posts/new`);
349 // TODO: fix this test
350 // previous entry data is somehow not cleared from the editor when opening new post
351 // cy.get('[id^="title-field"]').should('have.value', '');
352
353 exitEditor();
354}
355
356function createPostPublishAndDuplicate(entry) {
357 newPost();

Calls 4

newPostFunction · 0.85
populateEntryFunction · 0.85
publishEntryFunction · 0.85
exitEditorFunction · 0.85

Tested by

no test coverage detected