Skip to content

Checking Token

Checking Token #1524

Workflow file for this run

name: Tool Tests
env:
MICROSOFT_EMAIL: gindibay@microsoft.com
USER_NAME: Gurkan Indibay
MAIN_BRANCH: all-citus
on:
push:
branches:
- "**"
workflow_dispatch:
jobs:
make-install:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v3
- name: Install all scripts
run: make && sudo make install
unit_test_execution:
runs-on: ubuntu-latest
steps:
- name: Create GitHub App token
id: app
uses: actions/create-github-app-token@v1
with:
app-id: ${{ vars.GH_APP_ID }}
private-key: ${{ secrets.GH_APP_KEY }}
owner: ${{ github.repository_owner }}
- name: Set GH_TOKEN for all steps
run: echo "GH_TOKEN=${{ steps.app.outputs.token }}" >> $GITHUB_ENV
- name: Configure git with x-access-token
run: git config --global url."https://x-access-token:${{ steps.app.outputs.token }}@github.com/".insteadOf "https://github.com/"
- name: Checkout repository
uses: actions/checkout@v3
with:
token: ${{ steps.app.outputs.token }}
fetch-depth: 0
- name: Set up Python 3.10
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Define git credentials
run: git config --global user.email "${MICROSOFT_EMAIL}"&& git config --global user.name "${USER_NAME}"
- name: Install package dependencies
run: sudo apt-get update && sudo apt-get install libcurl4-openssl-dev libssl-dev python3-testresources
- name: Install python requirements
run: python -m pip install -r packaging_automation/requirements.txt
- name: Run static code analysis
run: python -m prospector
- name: Validate code format
run: black . --check
- name: Unit tests for "Common tools"
run: python -m pytest -q packaging_automation/tests/test_common_tool_methods.py
- name: Unit tests for "Update Package Properties"
run: python -m pytest -q packaging_automation/tests/test_update_package_properties.py
# no longer viable, outdated test, skipping to not block the pipeline
# - name: Unit tests for "Prepare Release"
# run: python -m pytest -q packaging_automation/tests/test_prepare_release.py
- name: Unit tests for "Update Docker"
run: python -m pytest -q packaging_automation/tests/test_update_docker.py
- name: Unit tests for "Update Pgxn"
run: python -m pytest -q packaging_automation/tests/test_update_pgxn.py
- name: Packaging Warning Handler
run: python -m pytest -q packaging_automation/tests/test_packaging_warning_handler.py