Skip to content

Commit

Permalink
ci: add inputs to workflow call of ci and release (#3488)
Browse files Browse the repository at this point in the history
* ci: Add dynamic input for Python versions and frontend tests folder in CI workflow.

* build: Update python versions to ['3.10', '3.11', '3.12'] and set frontend tests folder to 'tests'
  • Loading branch information
ogabrielluiz authored Aug 22, 2024
1 parent 450cc20 commit 280d1ca
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
15 changes: 13 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,17 @@ name: CI

on:
workflow_call:
inputs:
python-versions:
description: "Python Versions"
required: false
type: string
default: "['3.10']"
frontend-tests-folder:
description: "Frontend Tests Folder"
required: false
type: string
default: "tests/end-to-end"
workflow_dispatch:
inputs:
branch:
Expand Down Expand Up @@ -63,15 +74,15 @@ jobs:
if: ${{ needs.path-filter.outputs.python == 'true' || needs.path-filter.outputs.tests == 'true' }}
uses: ./.github/workflows/python_test.yml
with:
python-versions: "['3.10']"
python-versions: ${{ inputs.python-versions }}

test-frontend:
needs: path-filter
name: Run Frontend Tests
if: ${{ needs.path-filter.outputs.python == 'true' || needs.path-filter.outputs.frontend == 'true' || needs.path-filter.outputs.tests == 'true' }}
uses: ./.github/workflows/typescript_test.yml
with:
tests_folder: "tests/end-to-end"
tests_folder: ${{ inputs.frontend-tests-folder }}
secrets:
OPENAI_API_KEY: "${{ secrets.OPENAI_API_KEY }}"
STORE_API_KEY: "${{ secrets.STORE_API_KEY }}"
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,9 @@ jobs:
if: ${{ github.event.inputs.release_package_base == 'true' || github.event.inputs.release_package_main == 'true' }}
name: CI
uses: ./.github/workflows/ci.yml
with:
python-versions: "['3.10', '3.11', '3.12']"
frontend-tests-folder: "tests"

release-base:
name: Release Langflow Base
Expand Down

0 comments on commit 280d1ca

Please sign in to comment.