Skip to content

Commit

Permalink
Remove testing pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
sekaranglila authored Aug 15, 2024
1 parent 6ea0db3 commit 0ff7416
Showing 1 changed file with 45 additions and 46 deletions.
91 changes: 45 additions & 46 deletions .github/workflows/generate-release-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,64 +4,63 @@ on:
types: [create-release-tag]

jobs:
testing:
runs-on: ubuntu-latest
strategy:
matrix:
php-version:
- "7.4"
- "8.0"
- "8.1"
- "8.2"
# testing:
# runs-on: ubuntu-latest
# strategy:
# matrix:
# php-version:
# - "7.4"
# - "8.0"
# - "8.1"
# - "8.2"

steps:
- uses: actions/checkout@v3
# steps:
# - uses: actions/checkout@v3

- name: Print php version
run: echo ${{ matrix.php-version }}
# - name: Print php version
# run: echo ${{ matrix.php-version }}

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: ${{ matrix.php-version }}
# - name: Setup PHP
# uses: shivammathur/setup-php@v2
# with:
# php-version: ${{ matrix.php-version }}

- name: Print php version
run: php --version
# - name: Print php version
# run: php --version

- name: Install dependencies
run: composer install
# - name: Install dependencies
# run: composer install

- name: Run Tests
run: DEVELOPMENT_API_KEY=${{ secrets.DEVELOPMENT_API_KEY }} BUSINESS_ID=${{ secrets.BUSINESS_ID }} composer test
# - name: Run Tests
# run: DEVELOPMENT_API_KEY=${{ secrets.DEVELOPMENT_API_KEY }} BUSINESS_ID=${{ secrets.BUSINESS_ID }} composer test

send-test-result:
name: Slack Notification
needs: [testing]
if: always() && (needs.testing.result == 'success' || needs.testing.result == 'failure')
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
# send-test-result:
# name: Slack Notification
# needs: [testing]
# if: always() && (needs.testing.result == 'success' || needs.testing.result == 'failure')
# runs-on: ubuntu-latest
# steps:
# - uses: actions/checkout@v3

- name: Set Slack Color
id: set_color
run: |
if [ "${{ needs.testing.result }}" == "success" ]; then
echo "color=good" >> $GITHUB_ENV
else
echo "color=danger" >> $GITHUB_ENV
fi
# - name: Set Slack Color
# id: set_color
# run: |
# if [ "${{ needs.testing.result }}" == "success" ]; then
# echo "color=good" >> $GITHUB_ENV
# else
# echo "color=danger" >> $GITHUB_ENV
# fi

- name: Send Slack Notification
uses: rtCamp/action-slack-notify@v2
env:
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
SLACK_TITLE: "[xendi-php] CI pipeline for ${{ github.event.client_payload.version }}"
SLACK_MESSAGE: 'Test Result: ${{ needs.testing.result }}'
SLACK_COLOR: ${{ steps.set_color.outputs.color }}
# - name: Send Slack Notification
# uses: rtCamp/action-slack-notify@v2
# env:
# SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
# SLACK_TITLE: "[xendi-php] CI pipeline for ${{ github.event.client_payload.version }}"
# SLACK_MESSAGE: 'Test Result: ${{ needs.testing.result }}'
# SLACK_COLOR: ${{ steps.set_color.outputs.color }}

publish:
runs-on: ubuntu-latest
needs: testing
steps:
- uses: actions/checkout@v3

Expand Down

0 comments on commit 0ff7416

Please sign in to comment.