Skip to content
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

Implement Pytest PR #13

Merged
merged 4 commits into from
Oct 24, 2022
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions .github/workflows/pytest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Pytest PR
on:
pull-request:
branches:
- main
jobs:
run-test-code:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.9
uses: actions/setup-python@v4
with:
python-version: '3.9'
cache: 'pip'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pytest
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
yongchand marked this conversation as resolved.
Show resolved Hide resolved
- name: Test with pytest
yongchand marked this conversation as resolved.
Show resolved Hide resolved
run: |
export KLAYTN_ETL_RUN_SLOW_TESTS=True
pytest

13 changes: 13 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
web3>=5.29,<6
eth-rlp<0.3
eth-utils==1.10
eth-abi==2.1.1
# TODO: This has to be removed when "ModuleNotFoundError: No module named 'eth_utils.toolz'" is fixed at eth-abi
python-dateutil>=2.8.0,<3
click==8.0.4
ethereum-dasm==0.1.4
pytz==2022.1
base58
requests
boto3
google-cloud-storage
22 changes: 5 additions & 17 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ def version():
except:
return "0.0.0.dev0"

with open('requirements.txt') as f:
requirements = f.read().splitlines()

long_description = read('README.md') if os.path.isfile("README.md") else ""

setup(
Expand All @@ -31,26 +34,11 @@ def version():
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9'
'Programming Language :: Python :: 3.9',
],
keywords=['klaytn', 'etl', 'batch'],
python_requires='>=3.7.2,<4',
install_requires=[
'web3>=5.29,<6',
# eth-rlp is explicitly written to prevent dependency related issue
'eth-rlp<0.3',
'eth-utils==1.10',
'eth-abi==2.1.1',
# TODO: This has to be removed when "ModuleNotFoundError: No module named 'eth_utils.toolz'" is fixed at eth-abi
'python-dateutil>=2.8.0,<3',
'click==8.0.4',
'ethereum-dasm==0.1.4',
'pytz==2022.1',
'base58',
'requests',
'boto3',
'google-cloud-storage'
],
install_requires=requirements,
extras_require={
'dev': [
'pytest~=4.3.0'
Expand Down