Skip to content

Commit

Permalink
making py-test same as test was, in hopes it will run
Browse files Browse the repository at this point in the history
  • Loading branch information
robinsteuteville committed Feb 23, 2024
1 parent dbaf3fa commit 9598964
Show file tree
Hide file tree
Showing 2 changed files with 56 additions and 56 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/py-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ on:
# - "python/**"
# - "rust/**"
workflow_dispatch:
workflow_call:
# workflow_call:

jobs:
# call-rust-tests:
Expand Down
110 changes: 55 additions & 55 deletions .github/workflows/rust-tests.yaml
Original file line number Diff line number Diff line change
@@ -1,55 +1,55 @@
name: tests

on:
push:
branches: [fastsim-2, fastsim-3]
# paths:
# - "rust/**"
pull_request:
# paths:
# - "rust/**"
workflow_dispatch:
workflow_call:

jobs:
test:
# might not be needed
# if: github.repository == 'nrel/fastsim'

runs-on: ubuntu-latest

strategy:
fail-fast: true
matrix:
python-version: ['3.8', '3.9', '3.10']

env:
PYTHON: ${{ matrix.python-version }}

steps:
- uses: actions/checkout@v3

- name: set up python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

# if: contains(github.event.pull_request.changed_files, 'rust/')
- name: install rust
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true

- name: Rust unit tests
run: |
cd rust/ && cargo test
# in altrios, also includes python tests here, not sure I
# understand what added benefit this gives

- name: Python unit tests
run: |
pip install -e ".[dev]" && pytest -v python/fastsim/tests/
pytest -v python/fastsim/demos/
# name: tests

# on:
# push:
# branches: [fastsim-2, fastsim-3]
# # paths:
# # - "rust/**"
# pull_request:
# # paths:
# # - "rust/**"
# workflow_dispatch:
# # workflow_call:

# jobs:
# test:
# # might not be needed
# # if: github.repository == 'nrel/fastsim'

# runs-on: ubuntu-latest

# strategy:
# fail-fast: true
# matrix:
# python-version: ['3.8', '3.9', '3.10']

# env:
# PYTHON: ${{ matrix.python-version }}

# steps:
# - uses: actions/checkout@v3

# - name: set up python ${{ matrix.python-version }}
# uses: actions/setup-python@v4
# with:
# python-version: ${{ matrix.python-version }}

# # if: contains(github.event.pull_request.changed_files, 'rust/')
# - name: install rust
# uses: actions-rs/toolchain@v1
# with:
# profile: minimal
# toolchain: stable
# override: true

# - name: Rust unit tests
# run: |
# cd rust/ && cargo test

# # in altrios, also includes python tests here, not sure I
# # understand what added benefit this gives

# - name: Python unit tests
# run: |
# pip install -e ".[dev]" && pytest -v python/fastsim/tests/
# pytest -v python/fastsim/demos/

0 comments on commit 9598964

Please sign in to comment.