Skip to content

VM test runner rewrite #4088

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

Open
wants to merge 30 commits into
base: master
Choose a base branch
from
Open

Conversation

am1r021
Copy link
Contributor

@am1r021 am1r021 commented May 20, 2025

This change aims to modernize the vm test runners by switching over from using tape to vitest, refining the test file reader, and dropping any unused features or parameters of the current test runners.

Copy link

codecov bot commented May 20, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 79.34%. Comparing base (ad2fd6d) to head (6a48353).

Additional details and impacted files

Impacted file tree graph

Flag Coverage Δ
block 84.33% <ø> (ø)
blockchain 89.32% <ø> (ø)
client 67.61% <ø> (ø)
common 97.50% <ø> (ø)
devp2p 86.78% <ø> (ø)
evm 73.08% <ø> (ø)
mpt 89.74% <ø> (ø)
statemanager 69.06% <ø> (ø)
static 99.11% <ø> (ø)
tx 89.83% <ø> (ø)
util 88.69% <ø> (ø)
vm 55.31% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

pre: Record<string, AccountState>
post: Partial<Record<ForkName, PostReceipt[]>>
transaction: BlobTransaction
}
Copy link
Member

Choose a reason for hiding this comment

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

These types are added with the following commit message "Add types for vm state test data", so with "vm" in the text, while the types here are in "tx", so there seems to be something off.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, good point, they would have had to have been moved over to the vm package along with making getTests and other helpers in testLoader.ts available there too for use with the new runners. But we could leave that as a potential followup.

Copy link
Member

Choose a reason for hiding this comment

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

Side note if we/you tackle later: these tx specific things should never make it over, there should definitely no unified runner, only a very very lightweight unified 20 line file loader (as outlined in the chat) helper function, which is completely independent of whatever VM or TX code and can therefore be placed in a generic place (testdata package).

@am1r021 am1r021 force-pushed the tape-to-vitest-refactor-vm-testrunners branch from 7592482 to e39ed30 Compare May 22, 2025 17:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants