Skip to content

Commit

Permalink
Add test workflow with mint and wallet from different branches
Browse files Browse the repository at this point in the history
  • Loading branch information
sihamon committed Nov 12, 2023
1 parent e590fcf commit 88df088
Showing 1 changed file with 78 additions and 0 deletions.
78 changes: 78 additions & 0 deletions .github/workflows/separate_tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
name: compatibility

on: push

jobs:
poetry:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-latest ]
python-version: [ "3.10.4" ]
poetry-version: [ "1.5.1" ]
db-url: [""]
mint-branch: [main]
wallet-branch: ['tests/separate_mint_wallet' ]
steps:
- name: Checkout mint branch
uses: actions/checkout@v4
with:
ref: ${{ matrix.mint-branch}}
path: mint
submodules: recursive
token: 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
- name: Checkout wallet branch
uses: actions/checkout@v4
with:
ref: ${{ matrix.wallet-branch}}
path: wallet
submodules: recursive
token: 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
- name: Set up Poetry ${{ matrix.poetry-version }}
uses: abatilo/actions-poetry@v2
with:
poetry-version: ${{ matrix.poetry-version }}
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: "poetry"
- name: Install dependencies mint
run: |
poetry install --extras pgsql
shell: bash
working-directory: mint
- name: Install dependencies wallet
run: |
poetry install --extras pgsql
shell: bash
working-directory: wallet
- name: Mint tests
env:
LIGHTNING: false
WALLET_NAME: test_wallet
MINT_HOST: localhost
MINT_PORT: 3337
MINT_DATABASE: ${{ matrix.db-url }}
MINT_PRIVATE_KEY: "TEST_PRIVATE_KEY"
TOR: false
run: |
poetry run pytest tests --cov-report xml --cov cashu
working-directory: mint
- name: Wallet tests
env:
LIGHTNING: false
WALLET_NAME: test_wallet
MINT_HOST: localhost
MINT_PORT: 3337
MINT_DATABASE: ${{ matrix.db-url }}
MINT_PRIVATE_KEY: "TEST_PRIVATE_KEY"
TOR: false
run: |
poetry run mint
poetry run pytest tests/wallet --cov-report xml --cov cashu
poetry run pytest tests/common --cov-report xml --cov cashu
working-directory: wallet



0 comments on commit 88df088

Please sign in to comment.