Skip to content

Commit

Permalink
Run CI tests on any branch
Browse files Browse the repository at this point in the history
  • Loading branch information
pjcdawkins committed Dec 3, 2024
1 parent c60c516 commit 60e488e
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml → .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: CI
name: Build

on:
push:
Expand All @@ -9,7 +9,7 @@ on:
- main

jobs:
build-and-test:
test-and-build:
runs-on: ubuntu-24.04

steps:
Expand Down
47 changes: 47 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Test

on:
push:
branches:
pull_request:
branches:

jobs:
test:
runs-on: ubuntu-24.04

steps:
- uses: actions/checkout@v4

- name: Get Composer Cache Directory
id: composer-cache
run: |
echo "cache_dir=$(composer config cache-files-dir)" >> $GITHUB_ENV
- uses: actions/cache@v4
with:
path: ${{ env.cache_dir }}
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.lock') }}
restore-keys: |
${{ runner.os }}-composer-
- name: Install dependencies
run: |
composer install --no-dev --no-interaction --no-scripts
- name: Run PHPUnit tests
run: |
composer install --no-interaction --no-scripts
./scripts/test/unit.sh
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: 1.22
cache-dependency-path: cli/go.sum

- name: Run integration tests
run: |
export TEST_CLI_PATH=$(realpath "./bin/platform")
cd go-tests
go test ./... -v

0 comments on commit 60e488e

Please sign in to comment.