Skip to content

Commit 1a47f3b

Browse files
Merge pull request #4 from ElrondNetwork/added-workflow-and-missing-files
added workflow and missing files in root directory
2 parents a77dfc0 + 0e78958 commit 1a47f3b

13 files changed

Lines changed: 1164 additions & 0 deletions

File tree

.ctags

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
--exclude=*.html
2+
--exclude=*.md
3+
--exclude=.git
4+
--exclude=.gitignore
5+
--exclude=.vscode
6+
--exclude=README*
7+
--exclude=erdpy/tests/testdata/*
8+
--exclude=__pycache__
9+
--exclude=erdpy/ide/static/*

.flake8

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
[flake8]
2+
ignore = E501
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
2+
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
3+
4+
name: Publish erdpy
5+
6+
on:
7+
workflow_dispatch:
8+
9+
jobs:
10+
publish-erdpy:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- uses: actions/checkout@v2
15+
- name: Set up Python
16+
uses: actions/setup-python@v2
17+
with:
18+
python-version: '3.x'
19+
- name: Install dependencies
20+
run: |
21+
python3 -m pip install --upgrade pip
22+
pip3 install setuptools wheel twine
23+
- name: Build and publish
24+
env:
25+
TWINE_USERNAME: __token__
26+
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
27+
run: |
28+
python setup.py sdist bdist_wheel
29+
twine upload dist/*
30+
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Install erdpy using erdpy-up (MacOS)
2+
3+
on:
4+
pull_request:
5+
branches: [main, development]
6+
workflow_dispatch:
7+
8+
jobs:
9+
install-erdpy:
10+
runs-on: macos-latest
11+
12+
strategy:
13+
matrix:
14+
python-version: [3.8]
15+
16+
steps:
17+
- name: Set up Python ${{ matrix.python-version }}
18+
uses: actions/setup-python@v2
19+
with:
20+
python-version: ${{ matrix.python-version }}
21+
- name: Install
22+
run: |
23+
wget -O erdpy-up.py https://raw.githubusercontent.com/ElrondNetwork/elrond-sdk-erdpy/development/erdpy-up.py
24+
python3 erdpy-up.py <<< "2"
25+
- name: Smoke test
26+
run: |
27+
source /Users/runner/.bash_profile
28+
erdpy --version
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Install erdpy using erdpy-up (Ubuntu)
2+
3+
on:
4+
pull_request:
5+
branches: [main, development]
6+
workflow_dispatch:
7+
8+
jobs:
9+
install-erdpy:
10+
runs-on: ubuntu-latest
11+
12+
strategy:
13+
matrix:
14+
python-version: [3.8]
15+
16+
steps:
17+
- name: Set up Python ${{ matrix.python-version }}
18+
uses: actions/setup-python@v2
19+
with:
20+
python-version: ${{ matrix.python-version }}
21+
- name: Install
22+
run: |
23+
wget -O erdpy-up.py https://raw.githubusercontent.com/ElrondNetwork/elrond-sdk-erdpy/development/erdpy-up.py
24+
python3 erdpy-up.py
25+
- name: Smoke test
26+
run: |
27+
source /home/runner/.profile
28+
erdpy --version

.github/workflows/erdpy.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
2+
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
3+
4+
name: Build and Test erdpy
5+
6+
on:
7+
pull_request:
8+
branches: [ main, development ]
9+
workflow_dispatch:
10+
11+
jobs:
12+
build-erdpy:
13+
14+
runs-on: ubuntu-latest
15+
16+
strategy:
17+
matrix:
18+
python-version: [3.8]
19+
20+
steps:
21+
- uses: actions/checkout@v2
22+
- name: Set up Python ${{ matrix.python-version }}
23+
uses: actions/setup-python@v2
24+
with:
25+
python-version: ${{ matrix.python-version }}
26+
- name: Install dependencies
27+
run: |
28+
python3 -m pip install --upgrade pip
29+
pip3 install -r requirements.txt
30+
pip3 install pytest
31+
- name: Run unit tests
32+
run: |
33+
export PYTHONPATH=.
34+
python3 -m unittest discover -s erdpy/tests
35+
pytest ./erdpy/tests/test_testnet.py -s
36+
- name: Run CLI tests
37+
run: |
38+
cd ./erdpy/tests
39+
source ./test_cli_contracts.sh && testAll || return 1
40+
source ./test_cli_wallet.sh && testAll || return 1
41+
source ./test_cli_dns.sh && testOffline || return 1

.notags

Whitespace-only changes.

0 commit comments

Comments
 (0)