-
-
Notifications
You must be signed in to change notification settings - Fork 99
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add test workflow with mint and wallet from different branches
- Loading branch information
Showing
1 changed file
with
78 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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 | ||
|
||
|
||
|