diff --git a/.github/workflows/github-actions.yml b/.github/workflows/github-actions.yml new file mode 100644 index 0000000..4bb8298 --- /dev/null +++ b/.github/workflows/github-actions.yml @@ -0,0 +1,35 @@ +on: + push: + + # Allow manually triggering of the workflow. + workflow_dispatch: + inputs: + debug_enabled: + type: boolean + description: 'Run the build with tmate debugging enabled (https://github.com/marketplace/actions/debugging-with-tmate)' + required: false + default: false + +jobs: + run-sdk-tester: + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + language: [ 'node', 'php', 'python', 'ruby', 'dotnet', 'java' ] + steps: + - uses: actions/checkout@v3 + - name: run sdk tester + env: + API_KEY: ${{ secrets.API_KEY }} + LANGUAGE: ${{ matrix.language }} + SERVER: 'api.hellosign.com' + run: | + ./build ${{ matrix.language }} + pip install -U pytest + pytest -svra tests/ + + # Enable tmate debugging of manually-triggered workflows if the input option was provided + - name: Setup tmate session + uses: mxschmitt/action-tmate@v3 + if: ${{ github.event_name == 'workflow_dispatch' && inputs.debug_enabled }}