2022-07-16 12:10:43 +00:00
|
|
|
name: regtest
|
|
|
|
|
2022-10-06 16:51:36 +00:00
|
|
|
on: [push, pull_request]
|
2022-07-16 12:10:43 +00:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
LndRestWallet:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
strategy:
|
|
|
|
matrix:
|
2022-09-27 15:44:52 +00:00
|
|
|
python-version: ["3.9"]
|
2022-12-27 12:20:07 +00:00
|
|
|
poetry-version: ["1.3.1"]
|
2022-07-16 12:10:43 +00:00
|
|
|
steps:
|
2023-01-29 10:46:20 +00:00
|
|
|
- uses: actions/checkout@v3
|
2022-09-27 15:44:52 +00:00
|
|
|
- name: Set up Poetry ${{ matrix.poetry-version }}
|
|
|
|
uses: abatilo/actions-poetry@v2
|
|
|
|
with:
|
|
|
|
poetry-version: ${{ matrix.poetry-version }}
|
2023-01-29 10:46:20 +00:00
|
|
|
- name: Set up Python ${{ matrix.python-version }}
|
|
|
|
uses: actions/setup-python@v4
|
|
|
|
with:
|
|
|
|
python-version: ${{ matrix.python-version }}
|
|
|
|
cache: "poetry"
|
2022-07-16 12:10:43 +00:00
|
|
|
- name: Setup Regtest
|
|
|
|
run: |
|
2022-08-29 08:55:35 +00:00
|
|
|
docker build -t lnbitsdocker/lnbits-legend .
|
2022-07-16 12:10:43 +00:00
|
|
|
git clone https://github.com/lnbits/legend-regtest-enviroment.git docker
|
|
|
|
cd docker
|
2022-07-25 05:31:15 +00:00
|
|
|
chmod +x ./tests
|
|
|
|
./tests
|
2022-07-16 12:10:43 +00:00
|
|
|
sudo chmod -R a+rwx .
|
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
2022-08-03 12:10:32 +00:00
|
|
|
poetry install
|
2022-07-16 12:10:43 +00:00
|
|
|
- name: Run tests
|
|
|
|
env:
|
|
|
|
PYTHONUNBUFFERED: 1
|
|
|
|
PORT: 5123
|
|
|
|
LNBITS_DATA_FOLDER: ./data
|
|
|
|
LNBITS_BACKEND_WALLET_CLASS: LndRestWallet
|
|
|
|
LND_REST_ENDPOINT: https://localhost:8081/
|
2022-07-28 09:09:03 +00:00
|
|
|
LND_REST_CERT: ./docker/data/lnd-1/tls.cert
|
|
|
|
LND_REST_MACAROON: ./docker/data/lnd-1/data/chain/bitcoin/regtest/admin.macaroon
|
2022-07-16 12:10:43 +00:00
|
|
|
run: |
|
|
|
|
sudo chmod -R a+rwx . && rm -rf ./data && mkdir -p ./data
|
|
|
|
make test-real-wallet
|
2022-07-31 17:48:20 +00:00
|
|
|
- name: Upload coverage to Codecov
|
|
|
|
uses: codecov/codecov-action@v3
|
|
|
|
with:
|
2022-08-12 19:05:13 +00:00
|
|
|
file: ./coverage.xml
|
2022-08-09 09:49:39 +00:00
|
|
|
LndWallet:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
strategy:
|
|
|
|
matrix:
|
2022-09-27 15:44:52 +00:00
|
|
|
python-version: ["3.9"]
|
2022-12-27 12:20:07 +00:00
|
|
|
poetry-version: ["1.3.1"]
|
2022-08-09 09:49:39 +00:00
|
|
|
steps:
|
2023-01-29 10:46:20 +00:00
|
|
|
- uses: actions/checkout@v3
|
2022-09-27 15:44:52 +00:00
|
|
|
- name: Set up Poetry ${{ matrix.poetry-version }}
|
|
|
|
uses: abatilo/actions-poetry@v2
|
|
|
|
with:
|
|
|
|
poetry-version: ${{ matrix.poetry-version }}
|
2023-01-29 10:46:20 +00:00
|
|
|
- name: Set up Python ${{ matrix.python-version }}
|
|
|
|
uses: actions/setup-python@v4
|
|
|
|
with:
|
|
|
|
python-version: ${{ matrix.python-version }}
|
|
|
|
cache: "poetry"
|
2022-08-09 09:49:39 +00:00
|
|
|
- name: Setup Regtest
|
|
|
|
run: |
|
2022-08-29 08:55:35 +00:00
|
|
|
docker build -t lnbitsdocker/lnbits-legend .
|
2022-08-09 09:49:39 +00:00
|
|
|
git clone https://github.com/lnbits/legend-regtest-enviroment.git docker
|
|
|
|
cd docker
|
|
|
|
chmod +x ./tests
|
|
|
|
./tests
|
|
|
|
sudo chmod -R a+rwx .
|
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
|
|
|
poetry install
|
|
|
|
- name: Run tests
|
|
|
|
env:
|
|
|
|
PYTHONUNBUFFERED: 1
|
|
|
|
PORT: 5123
|
|
|
|
LNBITS_DATA_FOLDER: ./data
|
|
|
|
LNBITS_BACKEND_WALLET_CLASS: LndWallet
|
|
|
|
LND_GRPC_ENDPOINT: localhost
|
|
|
|
LND_GRPC_PORT: 10009
|
|
|
|
LND_GRPC_CERT: docker/data/lnd-1/tls.cert
|
|
|
|
LND_GRPC_MACAROON: docker/data/lnd-1/data/chain/bitcoin/regtest/admin.macaroon
|
|
|
|
run: |
|
|
|
|
sudo chmod -R a+rwx . && rm -rf ./data && mkdir -p ./data
|
2022-08-12 19:05:13 +00:00
|
|
|
make test-real-wallet
|
2022-08-09 09:49:39 +00:00
|
|
|
- name: Upload coverage to Codecov
|
|
|
|
uses: codecov/codecov-action@v3
|
|
|
|
with:
|
2022-08-12 19:05:13 +00:00
|
|
|
file: ./coverage.xml
|
2022-08-01 14:41:50 +00:00
|
|
|
CoreLightningWallet:
|
2022-07-16 12:10:43 +00:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
strategy:
|
|
|
|
matrix:
|
2022-09-27 15:44:52 +00:00
|
|
|
python-version: ["3.9"]
|
2022-12-27 12:20:07 +00:00
|
|
|
poetry-version: ["1.3.1"]
|
2022-07-16 12:10:43 +00:00
|
|
|
steps:
|
2023-01-29 10:46:20 +00:00
|
|
|
- uses: actions/checkout@v3
|
2022-09-27 15:44:52 +00:00
|
|
|
- name: Set up Poetry ${{ matrix.poetry-version }}
|
|
|
|
uses: abatilo/actions-poetry@v2
|
|
|
|
with:
|
|
|
|
poetry-version: ${{ matrix.poetry-version }}
|
2023-01-29 10:46:20 +00:00
|
|
|
- name: Set up Python ${{ matrix.python-version }}
|
|
|
|
uses: actions/setup-python@v4
|
|
|
|
with:
|
|
|
|
python-version: ${{ matrix.python-version }}
|
|
|
|
cache: "poetry"
|
2022-07-16 12:10:43 +00:00
|
|
|
- name: Setup Regtest
|
|
|
|
run: |
|
2022-08-29 08:55:35 +00:00
|
|
|
docker build -t lnbitsdocker/lnbits-legend .
|
2022-07-16 12:10:43 +00:00
|
|
|
git clone https://github.com/lnbits/legend-regtest-enviroment.git docker
|
|
|
|
cd docker
|
2022-07-25 05:31:15 +00:00
|
|
|
chmod +x ./tests
|
|
|
|
./tests
|
2022-07-16 12:10:43 +00:00
|
|
|
sudo chmod -R a+rwx .
|
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
2022-08-03 12:10:32 +00:00
|
|
|
poetry install
|
2022-07-16 12:10:43 +00:00
|
|
|
- name: Run tests
|
|
|
|
env:
|
|
|
|
PYTHONUNBUFFERED: 1
|
|
|
|
PORT: 5123
|
|
|
|
LNBITS_DATA_FOLDER: ./data
|
2022-08-01 14:41:50 +00:00
|
|
|
LNBITS_BACKEND_WALLET_CLASS: CoreLightningWallet
|
|
|
|
CORELIGHTNING_RPC: ./docker/data/clightning-1/regtest/lightning-rpc
|
2022-07-16 12:10:43 +00:00
|
|
|
run: |
|
|
|
|
sudo chmod -R a+rwx . && rm -rf ./data && mkdir -p ./data
|
2022-07-25 05:31:15 +00:00
|
|
|
make test-real-wallet
|
2022-07-31 17:48:20 +00:00
|
|
|
- name: Upload coverage to Codecov
|
|
|
|
uses: codecov/codecov-action@v3
|
|
|
|
with:
|
2022-08-03 12:10:32 +00:00
|
|
|
file: ./coverage.xml
|
2023-01-26 09:43:12 +00:00
|
|
|
LNbitsWallet:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
python-version: ["3.9"]
|
|
|
|
poetry-version: ["1.3.1"]
|
|
|
|
steps:
|
2023-01-29 10:46:20 +00:00
|
|
|
- uses: actions/checkout@v3
|
2023-01-26 09:43:12 +00:00
|
|
|
- name: Set up Poetry ${{ matrix.poetry-version }}
|
|
|
|
uses: abatilo/actions-poetry@v2
|
|
|
|
with:
|
|
|
|
poetry-version: ${{ matrix.poetry-version }}
|
2023-01-29 10:46:20 +00:00
|
|
|
- name: Set up Python ${{ matrix.python-version }}
|
|
|
|
uses: actions/setup-python@v4
|
|
|
|
with:
|
|
|
|
python-version: ${{ matrix.python-version }}
|
|
|
|
cache: "poetry"
|
2023-01-26 09:43:12 +00:00
|
|
|
- name: Setup Regtest
|
|
|
|
run: |
|
|
|
|
docker build -t lnbitsdocker/lnbits-legend .
|
|
|
|
git clone https://github.com/lnbits/legend-regtest-enviroment.git docker
|
|
|
|
cd docker
|
|
|
|
chmod +x ./tests
|
|
|
|
./tests
|
|
|
|
sudo chmod -R a+rwx .
|
|
|
|
docker exec lnbits-legend-lnbits-1 /bin/bash -c "poetry run python tools/create_fake_admin.py"
|
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
|
|
|
poetry install
|
|
|
|
- name: Run tests
|
|
|
|
env:
|
|
|
|
PYTHONUNBUFFERED: 1
|
|
|
|
PORT: 5123
|
|
|
|
LNBITS_DATA_FOLDER: ./data
|
|
|
|
LNBITS_BACKEND_WALLET_CLASS: LNbitsWallet
|
|
|
|
LNBITS_ENDPOINT: http://localhost:5001
|
|
|
|
LNBITS_KEY: "d08a3313322a4514af75d488bcc27eee"
|
|
|
|
run: |
|
|
|
|
sudo chmod -R a+rwx . && rm -rf ./data && mkdir -p ./data
|
|
|
|
make test-real-wallet
|
|
|
|
- name: Upload coverage to Codecov
|
|
|
|
uses: codecov/codecov-action@v3
|
|
|
|
with:
|
|
|
|
file: ./coverage.xml
|
2023-01-25 14:07:41 +00:00
|
|
|
EclairWallet:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
python-version: ["3.9"]
|
|
|
|
poetry-version: ["1.3.1"]
|
|
|
|
steps:
|
2023-01-29 10:46:20 +00:00
|
|
|
- uses: actions/checkout@v3
|
2023-01-25 14:07:41 +00:00
|
|
|
- name: Set up Poetry ${{ matrix.poetry-version }}
|
|
|
|
uses: abatilo/actions-poetry@v2
|
|
|
|
with:
|
|
|
|
poetry-version: ${{ matrix.poetry-version }}
|
2023-01-29 10:46:20 +00:00
|
|
|
- name: Set up Python ${{ matrix.python-version }}
|
|
|
|
uses: actions/setup-python@v4
|
|
|
|
with:
|
|
|
|
python-version: ${{ matrix.python-version }}
|
|
|
|
cache: "poetry"
|
2023-01-25 14:07:41 +00:00
|
|
|
- name: Setup Regtest
|
|
|
|
run: |
|
|
|
|
docker build -t lnbitsdocker/lnbits-legend .
|
|
|
|
git clone https://github.com/lnbits/legend-regtest-enviroment.git docker
|
|
|
|
cd docker
|
|
|
|
chmod +x ./tests
|
|
|
|
./tests
|
|
|
|
sudo chmod -R a+rwx .
|
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
|
|
|
poetry install
|
|
|
|
- name: Run tests
|
|
|
|
env:
|
|
|
|
PYTHONUNBUFFERED: 1
|
|
|
|
PORT: 5123
|
|
|
|
LNBITS_DATA_FOLDER: ./data
|
|
|
|
LNBITS_BACKEND_WALLET_CLASS: EclairWallet
|
|
|
|
ECLAIR_URL: http://127.0.0.1:8082
|
|
|
|
ECLAIR_PASS: lnbits
|
|
|
|
run: |
|
|
|
|
sudo chmod -R a+rwx . && rm -rf ./data && mkdir -p ./data
|
|
|
|
make test-real-wallet
|
|
|
|
- name: Upload coverage to Codecov
|
|
|
|
uses: codecov/codecov-action@v3
|
|
|
|
with:
|
2023-01-29 10:46:20 +00:00
|
|
|
file: ./coverage.xml
|