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

cypress: cleanup nasty waitInDevMode #380

Merged
merged 1 commit into from
Sep 6, 2021

Conversation

eh-am
Copy link
Collaborator

@eh-am eh-am commented Sep 5, 2021

Initially the cypress tests where flaky, as they were failing due the .then callbacks of fetch trying to access an unmounted component (think setState).
I added a nasty waitInDevMode to avoid that.
This PR cleans it up.

Since I was at it (ie. these weren't necessarily affecting the tests), I decided to add code to abort other requests too.

aborted requests when component is unmounting
which usually happens in cypress tests
since we click around faster than the server responds
@eh-am eh-am force-pushed the abort-request-when-changing-page branch from 43a1027 to c90fe06 Compare September 5, 2021 23:04
@codecov
Copy link

codecov bot commented Sep 5, 2021

Codecov Report

Merging #380 (c90fe06) into main (ce5fb76) will decrease coverage by 0.04%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #380      +/-   ##
==========================================
- Coverage   51.06%   51.02%   -0.03%     
==========================================
  Files         117      117              
  Lines        5251     5251              
==========================================
- Hits         2681     2679       -2     
- Misses       2311     2313       +2     
  Partials      259      259              
Impacted Files Coverage Δ
pkg/agent/upstream/remote/remote.go 62.32% <0.00%> (-2.89%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ce5fb76...c90fe06. Read the comment docs.

@grafana grafana deleted a comment from pyroscopebot Sep 5, 2021
Copy link
Member

@petethepig petethepig left a comment

Choose a reason for hiding this comment

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

Looks good to me. Thanks for fixing this @eh-am !

@petethepig petethepig merged commit c831911 into main Sep 6, 2021
@petethepig petethepig deleted the abort-request-when-changing-page branch September 6, 2021 07:21
korniltsev pushed a commit that referenced this pull request Jul 18, 2023
Update issue templates to include a bug template
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants