Skip to content

update

update #12

Workflow file for this run

name: Python package
on:
push:
paths:
- 'TNLS-Relayers/**'
- '.github/workflows/Python_tests.yml'
jobs:
build-and-test-python:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.8
uses: actions/setup-python@v4
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pytest
pip install -r requirements.txt
- name: Write Config File
working-directory: ./TNLS-Relayers
env:
INFURA_ENDPOINT: ${{ secrets.INFURA_ENDPOINT }}
run: |
touch infura_api_endpoint.txt
echo "$INFURA_ENDPOINT" > infura_api_endpoint.txt
- name: Start LocalSecret
working-directory: ./TNLS-Relayers
run: |
docker pull ghcr.io/scrtlabs/localsecret:v1.12.1
docker run -it -d -p 9091:9091 -p 26657:26657 -p 1317:1317 -p 5000:5000 --name localsecret ghcr.io/scrtlabs/localsecret:v1.12.1
sleep 60
- name: Install secretcli
run: |
wget https://github.com/scrtlabs/SecretNetwork/releases/download/v1.12.1/secretcli-Linux
chmod +x secretcli-Linux
sudo mv secretcli-Linux /usr/local/bin/secretcli
- name: Configure Secretcli to work with localSecret
working-directory: ./TNLS-Relayers/relayer_tests/interface_tests
run: |
chmod +x ./configure_secretcli.sh
./configure_secretcli.sh
- name: Upload contract to localSecret
working-directory: ./TNLS-Relayers/relayer_tests/interface_tests/test_scrt_contract
run: |
chmod +x ./upload_scrt_contract.sh
SGX_MODE=SW ./upload_scrt_contract.sh
- name: Test with pytest
working-directory: ./TNLS-Relayers
run: |
pytest
- name: Stop LocalSecret
working-directory: ./TNLS-Relayers
run: |
docker stop localsecret
docker rm localsecret