Skip to content

Conversation

@smiasojed
Copy link
Collaborator

@smiasojed smiasojed commented Oct 20, 2025

Related to: #294
Flags combination for the forge test command

Flag combination Compiler Runtime backend Target
(default) solc REVM Standard Foundry EVM test
--resolc resolc, solc pallet-revive (PVM) Run PolkaVM backend on pallet-revive
--resolc --polkadot resolc, solc pallet-revive (PVM) Run PolkaVM backend on pallet-revive
--polkadot (without resolc) resolc, solc pallet-revive (EVM) Run EVM backend on pallet-revive

TODO in next PRs:

  1. migrate EVM bytecode and set immutables
  2. Add vm cheatcodes, probably we should modify also flags

@smiasojed smiasojed marked this pull request as ready for review October 23, 2025 12:38
pub enum Item {
Data(Vec<u8>),
Array(Vec<Item>),
Array(Vec<Self>),
Copy link

Choose a reason for hiding this comment

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

why are this change needed, they don't seem related to the PR

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

It is reported by clippy

@alexggh
Copy link

alexggh commented Oct 24, 2025

This part needs updating as well:

revive_strategy::with_externalities(backend, f)
, otherwise --polkadot doesn't work well with forge test.

@alexggh
Copy link

alexggh commented Oct 24, 2025

Ran this with the tests from #334 and can confirm they are passing with REVM as the backend.

@smiasojed
Copy link
Collaborator Author

This part needs updating as well:

revive_strategy::with_externalities(backend, f)

, otherwise --polkadot doesn't work well with forge test.
thanks, added check for polkadot flag

@pkhry
Copy link

pkhry commented Oct 27, 2025

i assume that vm.pvm(true) cheatcode no longer serves a purpose?
if i run a test with --resolc(without --polkadot) startup migration is performed anyways.

@smiasojed
Copy link
Collaborator Author

i assume that vm.pvm(true) cheatcode no longer serves a purpose? if i run a test with --resolc(without --polkadot) startup migration is performed anyways.

yes, but it still works. In next PR I will add selection for evm or pvm

@smiasojed smiasojed merged commit 1ec2f82 into master Oct 28, 2025
52 of 61 checks passed
@smiasojed smiasojed deleted the sm/evm-support branch October 28, 2025 12:33
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.

4 participants