Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added Integration pages for Percy and App Percy for WDIO #12538

Merged
merged 16 commits into from
Mar 27, 2024

Conversation

KhushbuRander
Copy link
Contributor

@KhushbuRander KhushbuRander commented Mar 21, 2024

Proposed changes

Types of changes

  • Polish (an improvement for an existing feature)
  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update (improvements to the project's docs)
  • Specification changes (updates to WebDriver command specifications)
  • Internal updates (everything related to internal scripts, governance documentation and CI files)

Checklist

  • I have read the CONTRIBUTING doc
  • I have added tests that prove my fix is effective or that my feature works
  • I have added the necessary documentation (if appropriate)
  • I have added proper type definitions for new commands (if appropriate)

Backport Request

//: # (The current main branch is the development branch for WebdriverIO v9. If your change should be released to the current major version of WebdriverIO (v8), please raise another PR with the same changes against the v8 branch.)

  • This change is solely for v9 and doesn't need to be back-ported
  • Back-ported PR at #XXXXX

Further comments

Reviewers: @webdriverio/project-committers

Copy link

linux-foundation-easycla bot commented Mar 21, 2024

CLA Signed

The committers listed above are authorized under a signed CLA.

Copy link
Member

@christian-bromann christian-bromann left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Taking a first pass on this.

Comment on lines 166 to 167
"visual-testing/integrate-with-percy",
"visual-testing/integrate-with-app-percy"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we have Percy integration as its own category?

Suggested change
"visual-testing/integrate-with-percy",
"visual-testing/integrate-with-app-percy"
{
"type": "category",
"label": "Integrate with Percy",
"items": [
"visual-testing/integrate-with-percy",
"visual-testing/integrate-with-app-percy"
]
},

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BrowserStack's Percy and App Percy are two distinct products that fall under the larger Visual Testing space/domain. Percy is for visually testing web apps, whereas App Percy is for testing mobile apps. So, we would like this content to reside under the Visual Testing category.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This suggestion will keep Percy under the visual testing section, however I would like to have all related Percy content within a single category. We could call it:

Integrate with Percy

  • for web environments
  • for mobile apps

something along these lines. People are rather focused on the use case and not the branding itself and as of now these documents don't provide a clear differentiation.

The following example uses the percySnapshot() function in the async mode:

```sh
const percySnapshot = require('@percy/webdriverio');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's use ESM syntax here to stay consistent with the other examples on the docs. Feel free to have a code example with ESM and CJS as long as ESM is the default selection

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Incorporated comment.

```sh
const { remote } = require('webdriverio');
const percySnapshot = require('@percy/webdriverio');
(async () => {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here, the ESM version should not require an IIFE as root level await is supported

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Incorporated comment

@@ -0,0 +1,111 @@
---
id: integrate-with-app-percy
title: Integrate with App Percy
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How is this document different from the other. I've never used Percy so both docs seem to describe the same thing to me just slightly different. Can we make sure to give the documents better names that clarify the differentiation.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for asking. BrowserStack's Percy and App Percy are two distinct products that fall under the larger Visual Testing space/domain. If you want to compare visual differences between different versions/builds of your web app (on desktop and mobile browsers), you would use Percy.

If you want to compare visual differences between different versions of your mobile apps, then you should choose App Percy.

The similarities are because they both are visual testing platforms.

Hope this clarifies.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed the titles:
For Percy: Run visual tests on your web apps with Percy
For App Percy: Run visual tests on your mobile apps with App Percy

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we please make this very clear in the documents? I suggested above even a better title for the page, e.g. for web environments vs for mobile applications.

website/docs/visual-testing/integrate-with-app-percy.md Outdated Show resolved Hide resolved
website/docs/visual-testing/integrate-with-app-percy.md Outdated Show resolved Hide resolved
Comment on lines 10 to 21
WebdriverIO supports cross-browser visual testing natively using App Percy. You can use App Percy for visual testing of native mobile applications.
The benefits of utilizing App Percy for visual testing include the following:

- Consistency: Promotes consistent user experience by identifying visual discrepancies early in the development process.
- Efficiency: Improves efficiency by reducing the time and effort required to manually spot visual regressions.
- Integrations: Percy integrates with popular tools and services like GitHub, GitLab, Bitbucket, and more.
- Collaboration: Improves collaboration between developers, designers, and QA teams by providing a visual representation of changes.
- Prevent regression: Prevents you from experiencing unintended visual regressions.

## How does Percy work?

Percy compares new snapshots against relevant baselines to detect visual changes. Percy manages baseline selection across branches so your tests are always relevant. If visual changes are detected, Percy highlights and groups the resulting diffs for you to review.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This whole section is almost 1:1 the same to the other document. Let's maybe have a general page for Percy and then create 2 documents going into the specifics of using Percy for web environments and one for mobile applications

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. I have incorporated the suggested comments.

@@ -0,0 +1,144 @@
---
id: integrate-with-percy
title: Run visual tests on your web apps with Percy
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

instead of:

Run visual tests on your web apps with Percy
Run visual tests on your mobile apps with App Percy

Let's organize the content as:

Integrate with Percy
- For Web Apps
- For Mobile Apps

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. I have incorporated the suggested comments.

Copy link
Member

@christian-bromann christian-bromann left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some minor formatting issues which I will go ahead and merge, the rest looks good to me 👍 Thanks a lot!

@christian-bromann christian-bromann added the PR: Docs 📝 PRs that contain changes to the documentation label Mar 27, 2024
@christian-bromann christian-bromann merged commit 0a9ad84 into webdriverio:main Mar 27, 2024
8 checks passed
@christian-bromann
Copy link
Member

@KhushbuRander I will manually backport this patcht to v8 and publish the docs. No action needed from your side. Thanks again.

christian-bromann added a commit that referenced this pull request Mar 27, 2024
* cc

* c

* Percy changes

* Percy changes-1

* Update website/docs/visual-testing/integrate-with-app-percy.md

Co-authored-by: Christian Bromann <git@bromann.dev>

* Comment fixes

* Update integrate-with-app-percy.md

* Update integrate-with-percy.md

* Update integrate-with-app-percy.md

* Update integrate-with-percy.md

* Added Percy overview page

* Update website/docs/visual-testing/integrate-with-app-percy.md

* Update website/docs/visual-testing/integrate-with-percy.md

* Update website/docs/visual-testing/integrate-with-percy.md

* Update website/docs/visual-testing/integrate-with-percy.md

---------

Co-authored-by: Christian Bromann <git@bromann.dev>
JohnJoser3 pushed a commit to JohnJoser3/webdriverio-browserstack-docs that referenced this pull request May 3, 2024
…#12538)

* cc

* c

* Percy changes

* Percy changes-1

* Update website/docs/visual-testing/integrate-with-app-percy.md

Co-authored-by: Christian Bromann <git@bromann.dev>

* Comment fixes

* Update integrate-with-app-percy.md

* Update integrate-with-percy.md

* Update integrate-with-app-percy.md

* Update integrate-with-percy.md

* Added Percy overview page

* Update website/docs/visual-testing/integrate-with-app-percy.md

* Update website/docs/visual-testing/integrate-with-percy.md

* Update website/docs/visual-testing/integrate-with-percy.md

* Update website/docs/visual-testing/integrate-with-percy.md

---------

Co-authored-by: Christian Bromann <git@bromann.dev>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR: Docs 📝 PRs that contain changes to the documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants