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

Assign all unit tests using snake_oil_case_storage to same xdist thread #5390

Merged
merged 1 commit into from
May 11, 2023

Conversation

JHolba
Copy link
Contributor

@JHolba JHolba commented May 11, 2023

Issue
Several unit tests use snake_oil_case_storage that tries to cache the result of a snake_oil run. This cache is local to each xdist thread. Making sure that all unit tests using this pytest fixture run on the same thread will reduce the amount of times we need to run snake oil.

Approach
group all cases using snake_oil_case_storage in one xdist thread

Pre review checklist

  • Added appropriate release note label
  • PR title captures the intent of the changes, and is fitting for release notes.
  • Commit history is consistent and clean, in line with the contribution guidelines.
  • Updated documentation
  • Ensured new behaviour is tested

Adding labels helps the maintainers when writing release notes. This is the list of release note labels.

@codecov-commenter
Copy link

codecov-commenter commented May 11, 2023

Codecov Report

Merging #5390 (5ff6e81) into main (19a96ab) will increase coverage by 0.01%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##             main    #5390      +/-   ##
==========================================
+ Coverage   74.69%   74.70%   +0.01%     
==========================================
  Files         392      392              
  Lines       26785    26785              
  Branches     1931     1931              
==========================================
+ Hits        20008    20011       +3     
+ Misses       6135     6132       -3     
  Partials      642      642              

see 2 files with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@JHolba JHolba force-pushed the reduce-test-runners branch 2 times, most recently from 6bda456 to e73a337 Compare May 11, 2023 09:53
@JHolba JHolba changed the title Reduce time used by test runners Assign all unit tests using snake_oil_case_storage to same xdist thread May 11, 2023
increase timeout of test_job_runner_startup_overhead. the changes done by grouping tests seems to make it run slower now.
@JHolba JHolba marked this pull request as ready for review May 11, 2023 11:17
@JHolba JHolba requested a review from eivindjahren May 11, 2023 11:17
@JHolba JHolba enabled auto-merge (rebase) May 11, 2023 11:21
Copy link
Contributor

@eivindjahren eivindjahren left a comment

Choose a reason for hiding this comment

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

👍

@JHolba JHolba merged commit d8ca917 into equinor:main May 11, 2023
32 checks passed
@JHolba JHolba deleted the reduce-test-runners branch May 12, 2023 11:22
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.

None yet

3 participants