Skip to content

Commit

Permalink
Merge pull request #1288 from bluehost/PRESS0-2200-use-wb-in-launchpads
Browse files Browse the repository at this point in the history
PRESS0-2200: Update add new post and page launchpads with wb params
  • Loading branch information
wpalani authored Sep 4, 2024
2 parents ea788ae + 32863c1 commit a358b30
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/app/pages/pages-and-posts/blogPosts.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ const BlogPosts = () => {
<a href="edit.php">
{ __( 'View all', 'wp-plugin-bluehost' ) }
</a>
<a href="post-new.php">
<a href="post-new.php?wb-library=patterns&wb-category=text">
<Button>{ __( 'Add New', 'wp-plugin-bluehost' ) }</Button>
</a>
</div>
Expand Down
2 changes: 1 addition & 1 deletion src/app/pages/pages-and-posts/sitePages.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ const SitePages = () => {
<a href="edit.php?post_type=page">
{ __( 'View all', 'wp-plugin-bluehost' ) }
</a>
<a href="post-new.php?post_type=page">
<a href="post-new.php?post_type=page&wb-library=patterns&wb-category=features">
<Button onClick>
{ __( 'Add New', 'wp-plugin-bluehost' ) }
</Button>
Expand Down
8 changes: 4 additions & 4 deletions tests/cypress/integration/pages-and-posts.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@ describe('Pages & Posts', function () {
cy.go('back');

cy.get('.wppbh-app-site-page')
.find('a[href="post-new.php?post_type=page"] Button')
.find('a[href="post-new.php?post_type=page&wb-library=patterns&wb-category=features"] Button')
.click();
cy.url().should('include', 'post-new.php?post_type=page');
cy.url().should('include', 'post-new.php?post_type=page&wb-library=patterns&wb-category=features');
cy.go('back');
});

Expand All @@ -48,9 +48,9 @@ describe('Pages & Posts', function () {
cy.go('back');

cy.get('.wppbh-app-blog-posts')
.get('a[href="post-new.php"] Button')
.get('a[href="post-new.php?wb-library=patterns&wb-category=text"] Button')
.click();
cy.url().should('include', 'post-new.php');
cy.url().should('include', 'post-new.php?wb-library=patterns&wb-category=text');
cy.go('back');
});

Expand Down

0 comments on commit a358b30

Please sign in to comment.