Skip to content

Commit

Permalink
Condition for PR to main with windows updated
Browse files Browse the repository at this point in the history
  • Loading branch information
jitu5 committed Apr 11, 2024
1 parent f3001c7 commit da8b24e
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 4 deletions.
21 changes: 19 additions & 2 deletions .github/workflows/e2e-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,25 @@ on:
jobs:
e2e_tests:
runs-on: ${{ inputs.os }}
# Only run on main and demo branches for Windows
if: inputs.os == 'ubuntu-latest' || ((github.ref == 'refs/heads/main' || github.ref == 'refs/heads/demo') && inputs.os == 'windows-latest')

# below condition checks if the operating system is Ubuntu, or
# Run on Windows and
# main/demo branch or
# pull request to main with Python 3.10
if: >
inputs.os == 'ubuntu-latest' ||
(
(
github.ref == 'refs/heads/main' ||
github.ref == 'refs/heads/demo' ||
(
github.event.pull_request.base.ref == 'main' &&
inputs.python-version == '3.10'
)
) &&
inputs.os == 'windows-latest'
)
steps:
- name: Checkout code
uses: actions/checkout@v4
Expand Down
21 changes: 19 additions & 2 deletions .github/workflows/unit-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,25 @@ on:
jobs:
unit_tests:
runs-on: ${{ inputs.os }}
# Only run on main and demo branches for Windows
if: inputs.os == 'ubuntu-latest' || ((github.ref == 'refs/heads/main' || github.ref == 'refs/heads/demo') && inputs.os == 'windows-latest')

# below condition checks if the operating system is Ubuntu, or
# Run on Windows and
# main/demo branch or
# pull request to main with Python 3.10
if: >
inputs.os == 'ubuntu-latest' ||
(
(
github.ref == 'refs/heads/main' ||
github.ref == 'refs/heads/demo' ||
(
github.event.pull_request.base.ref == 'main' &&
inputs.python-version == '3.10'
)
) &&
inputs.os == 'windows-latest'
)
steps:
- name: Checkout code
uses: actions/checkout@v4
Expand Down

0 comments on commit da8b24e

Please sign in to comment.