Skip to content

New options to customize test runner

Latest
Compare
Choose a tag to compare
@ioedeveloper ioedeveloper released this 16 Mar 12:23
· 1 commit to main since this release
6998710

This release introduces new options to customize contract compilation and simulator provider.

Options

  evm-version:
    description: 'set evm version (e.g: istanbul, berlin etc)'
    required: false
  optimize:
    description: 'set optimize (e.g: true, false)'
    required: false
    default: 'false'
  optimizer-runs:
    description: 'set optimizer runs (e.g: 200)'
    required: false
    default: '0'
  node-url:
    description: 'set node url (e.g: https://mainnet.infura.io/v3/your-api-key)'
    required: false
  block-number:
    description: 'set block number (e.g: 123456)'
    required: false
    default: 'latest'
  hard-fork:
    description: 'set hard fork (e.g: istanbul, berlin etc. See full list of hard forks here: https://github.com/ethereumjs/ethereumjs-monorepo/tree/master/packages/common/src/hardforks)'
    required: false

Example

jobs:
  run_sample_test_job:
    runs-on: ubuntu-latest
    name: A job to run sample solidity tests
    steps:
      - name: Checkout
        uses: actions/checkout@v2
      - name: Environment Setup
        uses: actions/setup-node@v3
        with:
          node-version: 14.17.6
      - name: Run SUT action with default provider
        uses: EthereumRemix/[email protected]
        with:
          test-path: 'sample/tests/Ballot_test.sol'
          compiler-version: '0.8.15'
      - name: Run SUT Action with custom fork
        uses: EthereumRemix/[email protected]
        with:
          test-path: 'sample/tests/custom/hardFork_test.sol'
          compiler-version: '0.8.17'
          hard-fork: 'merge'
          node-url: 'https://mainnet.infura.io/v3/08b2a484451e4635a28b3d8234f24332'

Contributors

Yann Levreau @yann300, David Disu @ioedeveloper