Skip to content

Commit

Permalink
Forcing to show current directory of
Browse files Browse the repository at this point in the history
  • Loading branch information
pariterre committed Feb 7, 2024
1 parent 4bb5ae2 commit 67ed0f0
Show file tree
Hide file tree
Showing 4 changed files with 60 additions and 12 deletions.
34 changes: 29 additions & 5 deletions .github/workflows/run_frontend_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,33 @@ name: Run frontend tests
on: [pull_request]

jobs:
drive:
runs-on: ubuntu-latest
build:
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
label: Linux
prefix: /usr/share/miniconda3/envs/lokomat_fes
- os: macos-latest
label: Macos
prefix: /Users/runner/miniconda3/envs/lokomat_fes
- os: windows-latest
label: Windows
prefix: C:\Miniconda3\envs\lokomat_fes

name: Tests on ${{ matrix.label }}
runs-on: ${{ matrix.os }}
defaults:
run:
shell: bash -l {0}

steps:
- uses: actions/checkout@v1
- uses: subosito/flutter-action@v1
- run: flutter frontend/test
- name: Checkout code
uses: actions/checkout@v3

- name: Run tests
uses: subosito/flutter-action@v1
run: |
cd frontend
flutter test
11 changes: 9 additions & 2 deletions .github/workflows/run_server_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Run server tests
on: [pull_request]

env:
PYTHON_PATH: ../external/pyScienceMode/
PYTHON_PATH: ../server/external/pyScienceMode;./server/external/pyScienceMode;server/external/pyScienceMode;../server/external/pyScienceMode/;./server/external/pyScienceMode/;server/external/pyScienceMode/

jobs:
build:
Expand All @@ -30,6 +30,11 @@ jobs:
- name: Checkout code
uses: actions/checkout@v3

- name: Pull & update submodules recursively
run: |
git submodule update --init --recursive
git submodule update --recursive --remote
- name: Setup environment
uses: conda-incubator/setup-miniconda@v2
with:
Expand All @@ -46,7 +51,9 @@ jobs:
mamba list
- name: Install extra dependencies
run: mamba install black pytest pytest-cov codecov packaging -cconda-forge
run: |
mamba install black pytest pytest-cov codecov packaging -cconda-forge
- name: Run tests without coverage
run: pytest -v --color=yes server/tests
Expand Down
12 changes: 12 additions & 0 deletions server/examples/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,18 @@

_logger = logging.getLogger("lokomat_fes")

import os

print("coucou")
print(os.getcwd())
# print(os.environ["PYTHON_PATH"])
print(os.listdir("./"))
print(os.listdir("./server/"))
print(os.listdir("./server/external/"))
print(os.listdir("./server/external/pyScienceMode"))
print("coucou")
exit()


def _received_data(t: np.ndarray, data: np.ndarray) -> None:
"""Callback function that is called when new nidaq data are received"""
Expand Down
15 changes: 10 additions & 5 deletions server/tests/test_common_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,22 @@
import os
import pickle

# Print current working directory to the console
print("coucou")
print(os.getcwd())
print(os.listdir("./"))
print(os.listdir("./server/"))
print(os.listdir("./server/external/"))
print(os.listdir("./server/external/pyScienceMode"))
print(os.environ["PYTHON_PATH"])
print("coucou")

import numpy as np

from lokomat_fes import Data
from lokomat_fes.nidaq.data import NiDaqData
from lokomat_fes.rehastim.data import RehastimData, Channel

# Print current working directory to the console
print("coucou")
print(os.getcwd())
print("coucou")


def test_data_creation():
data = Data()
Expand Down

0 comments on commit 67ed0f0

Please sign in to comment.