Skip to content

Commit

Permalink
Merge pull request #42 from crytic/dev-gitactions
Browse files Browse the repository at this point in the history
Add gitactions based simple CI
  • Loading branch information
feliam authored Mar 24, 2020
2 parents eaac227 + c8b3bbb commit 521aa2b
Show file tree
Hide file tree
Showing 4 changed files with 74 additions and 1 deletion.
10 changes: 10 additions & 0 deletions .github/ISSUE_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
### pyvmasm version
<!--- pip show pyevmasm | grep Version --->

### Python version
<!--- python --version --->

### Summary of the problem
<!--- Try to include a script reproducing the issue --->


61 changes: 61 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: CI

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Set up Python 3.6
uses: actions/setup-python@v1
with:
python-version: 3.6
- name: Lint
if: github.event_name == 'pull_request'
env:
BASE_SHA: ${{ github.event.pull_request.base.sha }}
HEAD_SHA: ${{ github.event.pull_request.head.sha }}
run: |
pip install black
pip install mypy
python setup.py install
black --version
git diff --name-only $BASE_SHA..$HEAD_SHA | grep "*.py" | xargs black --diff --check
mypy --version
mypy pyevmasm
test37:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Set up Python 3.7
uses: actions/setup-python@v1
with:
python-version: 3.7
- name: Run Tests 37
run: |
python setup.py install
python -m unittest discover "tests/"
test27:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Set up Python 2.7
uses: actions/setup-python@v1
with:
python-version: 2.7
- name: Run Tests 27
run: |
python setup.py install
python -m unittest discover "tests/"
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
# pyevmasm
[![Build Status](https://github.com/crytic/pyevmasm/workflows/CI/badge.svg)](https://github.com/crytic/pyevmasm/actions?query=workflow%3ACI)

[![PyPI version](https://badge.fury.io/py/pyevmasm.svg)](https://badge.fury.io/py/pyevmasm)
[![Slack Status](https://empireslacking.herokuapp.com/badge.svg)](https://empireslacking.herokuapp.com)

Expand Down
2 changes: 1 addition & 1 deletion pyevmasm/evmasm.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from future.builtins import next, bytes # type: ignore
import copy

DEFAULT_FORK = "petersburg"
DEFAULT_FORK = "istanbul"

"""
Example use::
Expand Down

0 comments on commit 521aa2b

Please sign in to comment.