Giter Club home page Giter Club logo

Comments (41)

amrwahdan3 avatar amrwahdan3 commented on June 6, 2024 3

thanks @Robdel12 ! that did the trick i see snapshots being taken and uploaded now after updating to 0.8.3

from percy-cypress.

GordonTester avatar GordonTester commented on June 6, 2024 2

I'm seeing an issue with Percy not taking screenshots within my Cypress project. I've tried to point the tests to both a https and non https site and each time the tests pass in Cypress but fail within the Percy Dash as it was unable to find any screenshots.

When I run via chrome (and the cy GUI opens locally) I can see that the percy agent healthcheck is failing for some reason...

Any advice?

I am running my test using a script, as such:

"cy:run:percy": "export TEST_SUITE=foo; PERCY_TOKEN=xxx PERCY_BRANCH=test percy exec -- cypress run",

I can see it running in the terminal, bookended by percy calls

[percy] percy has started / ended etc....

from percy-cypress.

tinganho avatar tinganho commented on June 6, 2024 2

Seems to work now. Just deleted node_modules and reinstalled everything. Thanks!

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024 1

Hi there!

Percy can capture HTTPS websites. This seems a lot like there's CSP or CORS issues on the page blocking us from POSTing the DOM back to our node process. Can you try disabling Cypress web security and give it another shot?

from percy-cypress.

mapsandapps avatar mapsandapps commented on June 6, 2024 1

Hi @GordonTester, I had the same issue and downgrading to version 1.0.2 fixed it for me.

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024 1

Hey all! We had an issue with the 1.0.3 release but it should be fixed with 1.0.4. Can you give it a try and let us know? https://github.com/percy/percy-cypress/releases/tag/v1.0.4

from percy-cypress.

ericz82 avatar ericz82 commented on June 6, 2024 1

1.0.4 works for me. Looks like the healthcheck path fix did the trick!

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024 1

I believe this is safe to close now. If anyone sees any more issues with the healthcheck failing please comment and we'll reopen πŸ‘

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024 1

Hey @Uraz04, it looks like you're running on a network with a self signed cert (this won't work with Percy)

[percy] RequestError Error: self signed certificate in certificate chain

from percy-cypress.

tinganho avatar tinganho commented on June 6, 2024 1

@Robdel12 I cannot add that flag?

image

I tried before exec command as well

from percy-cypress.

skareemu avatar skareemu commented on June 6, 2024 1

Thank you so much @Robdel12, much appreciated . Issue is resolved with 9.1.1

from percy-cypress.

stijnbernards avatar stijnbernards commented on June 6, 2024

Hi, thank you for your response.

This does indeed seem to fix it.
Would be nice if we're able to get error logging about this issue.
I did see the part in the Percy Cypress docs about the websecurity.
But I did not receive any error logging at all :(

from percy-cypress.

mapsandapps avatar mapsandapps commented on June 6, 2024

@Robdel12 I did try 1.0.4, and I had the same issue as with 1.0.3.

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024

Can you share a little more about your setup? I'd be curious if there's any error logs or anything we can learn from what's going on there.

from percy-cypress.

mapsandapps avatar mapsandapps commented on June 6, 2024

I think that perhaps it is because we are using webpack, and require.resolve is returning a number instead of a path, similar to this issue.

from percy-cypress.

amrwahdan3 avatar amrwahdan3 commented on June 6, 2024

hello i am getting this issue. i dont get any snapshots and i get this error:
'Percy agent is not running. Skipping snapshots'

im running 3.3.2, my baseUrl in cypress.json is a https if that matters and i have the "chromeWebSecurity": false.
my tests are pretty basic:

describe('desktop home page tests', function () {

	beforeEach('SetUp', function () {
		cy.visit('/?flagoverride=flag1::true,flag2::false')
	})

	context('Desktop_Homepage_LayoutCorrect', function () {
		it('The layout is correct.', function () {
			cy.percySnapshot('Desktop Homepage')
		})
	})
})

this is also is the log:
[33mΒ»οΏ½[39m Warning: οΏ½[33mhealth-checkοΏ½[39m is not a percy command.↡Did you mean οΏ½[94mexecοΏ½[39m? [y/n]:

it happens in chrome and electron browser.

thanks

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024

Hey @amrwahdan3! It sounds like you're running an old version of @percy/agent with a new version of the Cypress SDK. Could you do an npm ls @percy/agent and post what the results of that are? v0.2.0 is when the healthcheck command was implemented: https://github.com/percy/percy-agent/blob/master/CHANGELOG.md#020-2019-04-03

Edit: I looked at one of your builds and can confirm that you're running @percy/agent 0.1.15

from percy-cypress.

james-hughes-ntt avatar james-hughes-ntt commented on June 6, 2024

I'm seeing the same issue that @amrwahdan3 was seeing.

[percy] stopping percy...
[percy] waiting for 0 snapshots to complete...
[percy] done.

I have the following setup:

  • @percy/agent
npm ls @percy/agent
[email protected] /Users/hughej/Projects/Personal/JavaScript/Cypress/cy-visual-tests
└─┬ @percy/[email protected]
  └── @percy/[email protected] 
  • package.json dependencies
"dependencies": {
    "@percy/cypress": "^2.3.1",
    "cypress": "^4.9.0",
    "cypress-image-snapshot": "^3.1.1",
    "prettier": "^2.0.5"
  }
  • cypress.json
{
    "video": false,
    "defaultTimeoutCommand": 5000,
    "pageLoadTimeout": 10000,
    "waitForAnimations": true,
    "chromeWebSecurity": false
}

Any help would be greatly appreciated. Thanks!

from percy-cypress.

amrwahdan3 avatar amrwahdan3 commented on June 6, 2024

@james-hughes-ntt i updated @percy/agent to the newest version like @Robdel12 suggested and that ended up working.

from percy-cypress.

james-hughes-ntt avatar james-hughes-ntt commented on June 6, 2024

Thanks. So after running npm ls @percy/agent it shows that I'm using @percy/[email protected] which appears to be the newest version. Not sure what else to try πŸ€·β€β™‚οΈ

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024

I don't believe this is a health check issue (unless you're seeing that specific log in Cypress command log). What test is calling cy.percySnapshot? Are there any logs around that?

from percy-cypress.

james-hughes-ntt avatar james-hughes-ntt commented on June 6, 2024

@Robdel12 I'm running percy exec -- cypress run
Here's the log from running that:

percy exec -- cypress run

[percy] created build #18 ...
[percy] percy has started.

====================================================================================================

  (Run Starting)

  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
  β”‚ Cypress:    4.9.0                                                                              β”‚
  β”‚ Browser:    Electron 80 (headless)                                                             β”‚
  β”‚ Specs:      1 found (percy.spec.js)                                                            β”‚
  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜


────────────────────────────────────────────────────────────────────────────────────────────────────
                                                                                                    
  Running:  percy.spec.js                                                                   (1 of 1)


  Visual Regression Testing with Percy and Cypress
    βœ“ should take a percy snapshot (1295ms)


  1 passing (4s)


  (Results)

  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
  β”‚ Tests:        1                                                                                β”‚
  β”‚ Passing:      1                                                                                β”‚
  β”‚ Failing:      0                                                                                β”‚
  β”‚ Pending:      0                                                                                β”‚
  β”‚ Skipped:      0                                                                                β”‚
  β”‚ Screenshots:  0                                                                                β”‚
  β”‚ Video:        false                                                                            β”‚
  β”‚ Duration:     3 seconds                                                                        β”‚
  β”‚ Spec Ran:     percy.spec.js                                                                    β”‚
  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜


====================================================================================================

  (Run Finished)


       Spec                                              Tests  Passing  Failing  Pending  Skipped  
  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
  β”‚ βœ”  percy.spec.js                            00:03        1        1        -        -        - β”‚
  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
    βœ”  All specs passed!                        00:03        1        1        -        -        -  

[percy] stopping percy...
[percy] waiting for 0 snapshots to complete...
[percy] done.

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024

Just to be 100% sure, what is the code for that test?

from percy-cypress.

james-hughes-ntt avatar james-hughes-ntt commented on June 6, 2024

Yeah good shout @Robdel12 . Pretty standard test.

describe('Visual Regression Testing with Percy and Cypress', () => {
    it('should take a percy snapshot', () => {
        cy.visit('https://www.example.com');
        cy.wait(1000);
        cy.percySnapshot;
    });
});

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024

Hey @james-hughes-ntt, thanks for that! Looks like you're missing the parens to invoke the function:

describe('Visual Regression Testing with Percy and Cypress', () => {
    it('should take a percy snapshot', () => {
        cy.visit('https://www.example.com');
        cy.wait(1000);
        cy.percySnapshot();
    });
});

from percy-cypress.

james-hughes-ntt avatar james-hughes-ntt commented on June 6, 2024

@Robdel12 ah thanks mate, yeah that was it! So duh of me. I was looking at all the places except for the most obvoius - where percy is actually invoked! Thanks again appreciate the help

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024

Ahhh, no worries! This happens to me all the time when doing support too. I get too far off in the weeds and it turns out it was something obvious :p

Happy it was something easy rather than something like the health check failing :D

from percy-cypress.

Uraz04 avatar Uraz04 commented on June 6, 2024

Hey there. Seems like I'm having the same issue as @james-hughes-ntt and I've checked the parens etc within the code but all seems fine (to me that is)..the below is the output and I can see something about the certificate but not sure if that's the issue. Also, disabled websecurity for chrome in the cypress.json file.

[email protected] cy:percy
percy exec -- cypress run

[percy] RequestError Error: self signed certificate in certificate chain | Wed Feb 03 2021 20:58:22 GMT+0000 (Greenwich Mean Time)
[percy] stopping percy...
[percy] waiting for 0 snapshots to complete...
[percy] done.
[percy] percy has started.

====================================================================================================

(Run Starting)

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Cypress: 6.3.0 β”‚
β”‚ Browser: Electron 87 (headless) β”‚
β”‚ Specs: 3 found (percy.spec.js, percy2.spec.js, Snapshot/image.spec.js) β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

────────────────────────────────────────────────────────────────────────────────────────────────────

Running: percy.spec.js (1 of 3)

Visual Regression test with Percy and Cypress
βœ“ should take percy snapshot (4559ms)

1 passing (6s)

(Results)

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Tests: 1 β”‚
β”‚ Passing: 1 β”‚
β”‚ Failing: 0 β”‚
β”‚ Pending: 0 β”‚
β”‚ Skipped: 0 β”‚
β”‚ Screenshots: 0 β”‚
β”‚ Video: false β”‚
β”‚ Duration: 6 seconds β”‚
β”‚ Spec Ran: percy.spec.js β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

────────────────────────────────────────────────────────────────────────────────────────────────────

Running: percy2.spec.js (2 of 3)

Visual Regression test with Percy and Cypress
βœ“ should take percy snapshot (3277ms)

1 passing (4s)

(Results)

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Tests: 1 β”‚
β”‚ Passing: 1 β”‚
β”‚ Failing: 0 β”‚
β”‚ Pending: 0 β”‚
β”‚ Skipped: 0 β”‚
β”‚ Screenshots: 0 β”‚
β”‚ Video: false β”‚
β”‚ Duration: 4 seconds β”‚
β”‚ Spec Ran: percy2.spec.js β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

────────────────────────────────────────────────────────────────────────────────────────────────────

Running: Snapshot/image.spec.js (3 of 3)

0 passing (0ms)

(Results)

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Tests: 0 β”‚
β”‚ Passing: 0 β”‚
β”‚ Failing: 0 β”‚
β”‚ Pending: 0 β”‚
β”‚ Skipped: 0 β”‚
β”‚ Screenshots: 0 β”‚
β”‚ Video: false β”‚
β”‚ Duration: 0 seconds β”‚
β”‚ Spec Ran: Snapshot/image.spec.js β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

====================================================================================================

(Run Finished)

   Spec                                              Tests  Passing  Failing  Pending  Skipped  

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ βœ” percy.spec.js 00:06 1 1 - - - β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ βœ” percy2.spec.js 00:04 1 1 - - - β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚ βœ” Snapshot/image.spec.js 2ms - - - - - β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
βœ” All specs passed! 00:10 2 2 - - -

[percy] stopping percy...
[percy] waiting for 0 snapshots to complete...
[percy] done.

from percy-cypress.

tinganho avatar tinganho commented on June 6, 2024

@Robdel12 I have tried to get Percy taking snapshot as well in Cypress. Tried all the above, and no missing parens. Also disabled web security. The only thing I can see is this:

image

from percy-cypress.

tinganho avatar tinganho commented on June 6, 2024

image

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024

What version are you using? This likely isn't related to this issue. The latest version of the SDK doesn't have a health check like this anymore.

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024

Also, the log there suggests Percy isn't running. Are you using percy exec -- cypress run with a PERCY_TOKEN set?

from percy-cypress.

tinganho avatar tinganho commented on June 6, 2024

I'm running with these versions:
image

image

from percy-cypress.

tinganho avatar tinganho commented on June 6, 2024

You disregard that font log. It doesnt work with a proper font as well.

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024

Can you set --verbose (npx percy exec --verbose -- ...) for debug logs? Looks like the network request to http://localhost:5338/percy/snapshot is failing for some reason. Curious if it's related to Cypress's 7.x networking bug in a different flavor. 🀨

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024

which percy? Smells like you have @percy/agent hanging around somewhere. --verbose is a new @percy/cli flag (and @percy/agent is replaced by @percy/cli)

from percy-cypress.

stuthib avatar stuthib commented on June 6, 2024

Hi, I am running into a missing snapshot issue. It is not consistent and I can't figure out the cause. I ran the command with --verbose and see this error.
Cypress: 6.9.1
"@percy/cli": "^1.0.0-beta.63"
"@percy/cypress": "^3.1.1"

     [percy:core] Error: Navigation failed: Timeout of 30000ms exceeded.
    at Timeout.check [as _onTimeout] (/node_modules/@percy/core/dist/utils.js:103:17)
    at listOnTimeout (node:internal/timers:559:11)
    at processTimers (node:internal/timers:500:7) (0ms)```

Any help would be much appreciated! 

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024

Hey @stuthib! That doesn't appear to be related to what this issue was about. Can you try upgrading @percy/cli to the latest (beta.68) and if that still is a problem open a new discussion on @percy/cli?

from percy-cypress.

stuthib avatar stuthib commented on June 6, 2024

@Robdel12 Thank you for the quick response. I updated @percy/cli and also set the timeout in percy config to 60000, while the default was 30000 and it was timing out on page navigation. The last few builds have not errored out and seems to be consistent. If I run into this issue again, I will open a new discussion on @percy/cli.

from percy-cypress.

skareemu avatar skareemu commented on June 6, 2024

@Robdel12 I am also running into the same issue. When I do --verbose, it says the below.

[percy:cypress] Could not take DOM snapshot "Dashboard Page" (36154ms)
[percy:cypress] Error: Missing required URL for snapshot
at request (https://customer.nintex.com/__cypress/tests?p=cypress\support\index.js:784:28)
at async Object.postSnapshot (https://customer.nintex.com/__cypress/tests?p=cypress\support\index.js:895:6) (5ms)

When I researched further, I came to know that it is working fine in my personal laptop, however in my company laptop it is not working. It appears like from my company laptop it is failing to connect to percy server or failing to get the build url or something like that. Appreciate if you could please look into it and advise me to resolve this issue. Please see complete console log below

---------------------------Here is the complete console log------------------
npx percy exec --verbose -- cypress run
[percy:config] Config file not found (0ms)
[percy:client] Creating a new build... (27ms)
[percy:core:browser] Launching browser (491ms)
[percy:core:browser] Browser connected: HeadlessChrome/92.0.4515.0 (117ms)
[percy:core] Percy has started! (3ms)
[percy:cli:exec] Running "cypress run" (0ms)

====================================================================================================

(Run Starting)

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Cypress: 9.1.0 β”‚
β”‚ Browser: Electron 94 (headless) β”‚
β”‚ Node Version: v16.13.1 (C:\Program Files\nodejs\node.exe) β”‚
β”‚ Specs: 1 found (visual_testing/purek2.spec.js) β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

────────────────────────────────────────────────────────────────────────────────────────────────────

Running: visual_testing/purek2.spec.js (1 of 1)
Browserslist: caniuse-lite is outdated. Please run:
npx browserslist@latest --update-db

Why you should do it regularly:
https://github.com/browserslist/browserslist#browsers-data-updating

Customer Central-Visual Testing
[percy:cypress] Could not take DOM snapshot "Dashboard Page" (36154ms)
[percy:cypress] Error: Missing required URL for snapshot
at request (https://customer.nintex.com/__cypress/tests?p=cypress\support\index.js:784:28)
at async Object.postSnapshot (https://customer.nintex.com/__cypress/tests?p=cypress\support\index.js:895:6) (5ms)
√ Pure K2 Permission checks - Dashboard Page (27854ms)

1 passing (28s)

(Results)

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Tests: 1 β”‚
β”‚ Passing: 1 β”‚
β”‚ Failing: 0 β”‚
β”‚ Pending: 0 β”‚
β”‚ Skipped: 0 β”‚
β”‚ Screenshots: 0 β”‚
β”‚ Video: true β”‚
β”‚ Duration: 27 seconds β”‚
β”‚ Spec Ran: visual_testing/purek2.spec.js β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

(Video)

  • Started processing: Compressing to 32 CRF
  • Finished processing: C:\Work\ntx_appdevit_automation\ncc_automation\cypress\vide (3 seconds)
    os\visual_testing\purek2.spec.js.mp4

====================================================================================================

(Run Finished)

   Spec                                              Tests  Passing  Failing  Pending  Skipped  

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ √ visual_testing/purek2.spec.js 00:27 1 1 - - - β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
√ All specs passed! 00:27 1 1 - - -

[percy:core:browser] Closing browser (4392ms)
[percy:client] Finalizing build 14402721... (135ms)
[percy:core] Finalized build #13: https://percy.io/3f3a16fc/ncc_automation/builds/14402721

from percy-cypress.

Robdel12 avatar Robdel12 commented on June 6, 2024

Hey @skareemu! Upgrade Cypress from 9.1 to 9.1.1: #437 (reply in thread) v9.1 has missing patched dependencies, which makes for some wonky bugs.

from percy-cypress.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.