diff --git a/.github/actions/test/action.yml b/.github/actions/test/action.yml index 42fd809b2ce..7fc58164839 100644 --- a/.github/actions/test/action.yml +++ b/.github/actions/test/action.yml @@ -1,14 +1,27 @@ name: Test Ice +inputs: + language: + description: "Language to test" + required: true + # default: "1" + # options: ["cpp", "csharp", "java", "python", "js", "swift", "php", "ruby"] + + flags: + description: "Flags to pass to the test" + required: false + default: "" + # options: ["cpp", "csharp", "java", "python", "js", "swift", "php", "ruby"] + runs: using: "composite" steps: - name: Test - run: python3 allTests.py --workers=3 + run: python3 allTests.py --workers=3 --language=${{ inputs.language }} {{ inputs.flags }} shell: bash if: startsWith(matrix.os, 'ubuntu') || startsWith(matrix.os, 'macos') - name: Test - run: python allTests.py --platform=x64 --workers=3 + run: python allTests.py --platform=x64 --workers=3 --language=${{ inputs.language }} {{ inputs.flags }}} shell: powershell if: startsWith(matrix.os, 'windows') diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 1fc6e3190a3..cd70c5635de 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,15 +16,18 @@ jobs: build: strategy: matrix: + language: [cpp, csharp, java, python, js] # available on all os os: [macos-latest, ubuntu-latest, windows-latest] + include: + - language: swift + os: macos-latest + - language: php + os: [ubuntu-latest, macos-latest] + - language: ruby + os: [ubuntu-latest, macos-latest] + runs-on: ${{ matrix.os }} steps: - - name: Setup Build Cache - uses: actions/cache@v3 - with: - path: . - key: ${{ runner.os }}-build-${{ github.sha }} - - name: Checkout repository uses: actions/checkout@v3 @@ -52,18 +55,7 @@ jobs: - name: Build ${{ matrix.os }} uses: ./.github/actions/build - test: - needs: build - strategy: - matrix: - os: [macos-latest, ubuntu-latest, windows-latest] - runs-on: ${{ matrix.os }} - steps: - - name: Restore Build Cache - uses: actions/cache@v3 - with: - path: . - key: ${{ runner.os }}-build-${{ github.sha }} - - name: Build ${{ matrix.os }} uses: ./.github/actions/test + with: + language: ${{ matrix.language }}