-
Notifications
You must be signed in to change notification settings - Fork 778
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
On-demand testing for VM State and Blockchain #951
Changes from all commits
342319b
40bdd4f
3fb8eb5
732ea8b
c0dd7ee
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,7 +11,7 @@ defaults: | |
working-directory: packages/vm | ||
|
||
jobs: | ||
test-vm-api: | ||
vm-api: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/setup-node@v1 | ||
|
@@ -49,21 +49,13 @@ jobs: | |
- run: npm run test:API:browser | ||
- run: npm run lint | ||
|
||
test-vm-state: | ||
vm-state: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
fork: [ | ||
# 'Berlin', | ||
'MuirGlacier', | ||
'Istanbul', | ||
# 'Petersburg', | ||
# 'Constantinople', | ||
# 'Byzantium', | ||
# 'SpuriousDragon', | ||
# 'TangerineWhistle', | ||
# 'Homestead', | ||
# 'Chainstart' | ||
'Istanbul' | ||
] | ||
fail-fast: false | ||
steps: | ||
|
@@ -93,7 +85,49 @@ jobs: | |
|
||
- run: npm run test:state -- --fork=${{ matrix.fork }} --verify-test-amount-alltests | ||
|
||
test-vm-blockchain: | ||
vm-state-extended: | ||
if: contains(join(github.event.pull_request.labels.*.name, ' '), 'Test all hardforks') | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
fork: [ | ||
'Berlin', | ||
'Petersburg', | ||
'Constantinople', | ||
'Byzantium', | ||
'SpuriousDragon', | ||
'TangerineWhistle', | ||
'Homestead', | ||
'Chainstart' | ||
] | ||
fail-fast: false | ||
steps: | ||
- uses: actions/setup-node@v1 | ||
with: | ||
node-version: 12.x | ||
- uses: actions/checkout@v1 | ||
with: | ||
submodules: recursive | ||
- name: Dependency cache | ||
uses: actions/cache@v2 | ||
id: cache | ||
with: | ||
key: VM-${{ runner.os }}-12-${{ hashFiles('**/package-lock.json') }} | ||
path: '**/node_modules' | ||
|
||
# Installs root dependencies, ignoring Bootstrap All script. | ||
# Bootstraps the current package only | ||
- run: npm install --ignore-scripts && npm run bootstrap:vm | ||
if: steps.cache.outputs.cache-hit != 'true' | ||
working-directory: ${{github.workspace}} | ||
|
||
# Builds current package and the ones it depends from. | ||
- run: npm run build:vm | ||
working-directory: ${{github.workspace}} | ||
|
||
- run: npm run test:state -- --fork=${{ matrix.fork }} --verify-test-amount-alltests | ||
|
||
vm-blockchain: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
|
@@ -102,15 +136,53 @@ jobs: | |
|
||
# Tests were splitted with --dir and --excludeDir to balance execution times below the 9min mark. | ||
args: [ | ||
# '--fork=Berlin --expected-test-amount=33', | ||
'--fork=Istanbul --dir=GeneralStateTests/stTimeConsuming --expected-test-amount=15561', | ||
'--fork=Istanbul --excludeDir=stTimeConsuming --expected-test-amount=19817', | ||
# '--fork=Constantinople --dir=GeneralStateTests/stTimeConsuming --expected-test-amount=15561', | ||
# '--fork=Constantinople --excludeDir=stTimeConsuming --expected-test-amount=17193', | ||
# '--fork=Petersburg --dir=GeneralStateTests/stTimeConsuming --expected-test-amount=15561', | ||
# '--fork=Petersburg --excludeDir=stTimeConsuming --expected-test-amount=17174', | ||
# '--fork=Homestead --expected-test-amount=6997', | ||
# '--fork=Chainstart --expected-test-amount=4385' | ||
'--fork=Istanbul --excludeDir=stTimeConsuming --expected-test-amount=19817' | ||
] | ||
fail-fast: false | ||
steps: | ||
- uses: actions/setup-node@v1 | ||
with: | ||
node-version: 12.x | ||
- uses: actions/checkout@v1 | ||
with: | ||
submodules: recursive | ||
- name: Dependency cache | ||
uses: actions/cache@v2 | ||
id: cache | ||
with: | ||
key: VM-${{ runner.os }}-12-${{ hashFiles('**/package-lock.json') }} | ||
path: '**/node_modules' | ||
|
||
# Installs root dependencies, ignoring Bootstrap All script. | ||
# Bootstraps the current package only | ||
- run: npm install --ignore-scripts && npm run bootstrap:vm | ||
if: steps.cache.outputs.cache-hit != 'true' | ||
working-directory: ${{github.workspace}} | ||
|
||
# Builds current package and the ones it depends from. | ||
- run: npm run build:vm | ||
working-directory: ${{github.workspace}} | ||
|
||
- run: npm run test:blockchain -- ${{ matrix.args }} | ||
|
||
vm-blockchain-extended: | ||
if: contains(join(github.event.pull_request.labels.*.name, ' '), 'Test all hardforks') | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. coool There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I could not use the entire label name There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. interesting, ok, good to know! and I noticed the label has a lowercase t for test. |
||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
# Args to pass to the tester. Note that some have splitted the slow tests and only | ||
# running those: these are only on forks where that is applicable (see PR #489 for numbers on these) | ||
|
||
# Tests were splitted with --dir and --excludeDir to balance execution times below the 9min mark. | ||
args: [ | ||
'--fork=Berlin --expected-test-amount=33', | ||
'--fork=Constantinople --dir=GeneralStateTests/stTimeConsuming --expected-test-amount=15561', | ||
'--fork=Constantinople --excludeDir=stTimeConsuming --expected-test-amount=17193', | ||
'--fork=Petersburg --dir=GeneralStateTests/stTimeConsuming --expected-test-amount=15561', | ||
'--fork=Petersburg --excludeDir=stTimeConsuming --expected-test-amount=17174', | ||
'--fork=Homestead --expected-test-amount=6997', | ||
'--fork=Chainstart --expected-test-amount=4385' | ||
] | ||
fail-fast: false | ||
steps: | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
[submodule "ethereum-tests"] | ||
path = ethereum-tests | ||
path = packages/ethereum-tests | ||
url = https://github.com/ethereum/tests.git | ||
branch = develop |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
did you mean to keep these commented out here, or should they be removed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ryanio they are OK to be removed. In fact, they were just moved to these lines: https://github.com/ethereumjs/ethereumjs-vm/pull/951/files/c13ce861a06ce6969e59ede971db755dc2490734#diff-8ac46f60fffb24cf4daf7b192aee8bcd313d6fba95b005aa644e40600739a713R173-R179