Skip to content

Conversation

bowenli86
Copy link
Contributor

@bowenli86 bowenli86 commented Feb 15, 2025

Motivation:

Foundry tests only need to run when specific codebase paths are modified, rather than for all changes.

For example, tests are not required when only documentation or deployment scripts are updated.

Modifications:

  • Added a list of code paths that trigger Foundry tests when modified.

Result:

  • Speeds up CI for non-core contract changes.
  • Reduces CI costs.

Copy link
Member

@0xClandestine 0xClandestine left a comment

Choose a reason for hiding this comment

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

Great idea, small change requested 🙏

@0xClandestine
Copy link
Member

Why aren't the foundry tests being skipped?

@0xClandestine
Copy link
Member

Why aren't the foundry tests being skipped?

Oh because .github/ is in path

@0xClandestine 0xClandestine changed the title perf: run tests only when certain code paths changes to speed up CI perf: run Foundry CI tests only for relevant code changes Feb 17, 2025
@0xClandestine 0xClandestine self-requested a review February 17, 2025 17:33
@0xClandestine 0xClandestine merged commit 525e09e into dev Feb 17, 2025
9 checks passed
@0xClandestine 0xClandestine deleted the perf/path branch February 17, 2025 17:55
@0xClandestine 0xClandestine added the ⚡ Optimization Performance or efficiency improvements. label Feb 17, 2025
ypatil12 pushed a commit that referenced this pull request Feb 22, 2025
**Motivation:**  

Foundry tests only need to run when specific codebase paths are
modified, rather than for all changes.

For example, tests are not required when only documentation or
deployment scripts are updated.

**Modifications:**  

- Added a list of code paths that trigger Foundry tests when modified.  

**Result:**  

- Speeds up CI for non-core contract changes.  
- Reduces CI costs.

---------

Co-authored-by: clandestine.eth <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
⚡ Optimization Performance or efficiency improvements.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants