diff --git a/.github/workflows/.tests-javascript.yml b/.github/workflows/.tests-javascript.yml new file mode 100644 index 00000000..1ad23aa4 --- /dev/null +++ b/.github/workflows/.tests-javascript.yml @@ -0,0 +1,34 @@ +name: Javascript CI + +on: + push: + paths: ['fittrackee_client'] + pull_request: + paths: ['fittrackee_client'] + +env: + working-directory: fittrackee_client + +jobs: + javascript: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Use Node.js 17.x + uses: actions/setup-node@v2 + with: + node-version: "17.x" + - name: Install yarn and dependencies + working-directory: ${{env.working-directory}} + run: | + npm install --global yarn + yarn install + - name: Lint + working-directory: ${{env.working-directory}} + run: yarn lint + - name: Tests + working-directory: ${{env.working-directory}} + run: yarn test:unit + - name: Build + working-directory: ${{env.working-directory}} + run: yarn build diff --git a/.github/workflows/.tests.yml b/.github/workflows/.tests-python.yml similarity index 81% rename from .github/workflows/.tests.yml rename to .github/workflows/.tests-python.yml index 587f3a68..4990fb53 100644 --- a/.github/workflows/.tests.yml +++ b/.github/workflows/.tests-python.yml @@ -1,6 +1,10 @@ -name: FitTrackee tests +name: Python CI -on: [push, pull_request] +on: + push: + paths-ignore: ['docs/**', 'docsrc/**', 'fittrackee_client', '*.md'] + pull_request: + paths-ignore: ['docs/**', 'docsrc/**', 'fittrackee_client', '*.md'] env: APP_SETTINGS: fittrackee.config.TestingConfig @@ -46,31 +50,9 @@ jobs: - name: Pytest run: pytest fittrackee -p no:warnings --cov fittrackee --cov-report term-missing - javascript: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Use Node.js 17.x - uses: actions/setup-node@v2 - with: - node-version: "17.x" - - name: Install yarn and dependencies - run: | - npm install --global yarn - cd fittrackee_client - yarn install - - name: Lint - run: | - cd fittrackee_client - yarn lint - - name: Tests - run: | - cd fittrackee_client - yarn test:unit - end2end: runs-on: ubuntu-latest - needs: ["python", "javascript"] + needs: ["python"] container: python:3.10 services: postgres: