Skip to content

Commit e996439

Browse files
committed
ci: replace circleci with github actions
1 parent 85b4a43 commit e996439

File tree

2 files changed

+67
-29
lines changed

2 files changed

+67
-29
lines changed

.circleci/config.yml

Lines changed: 0 additions & 29 deletions
This file was deleted.
Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
name: Drupal test routine
2+
3+
on:
4+
push:
5+
branches:
6+
- 'main'
7+
- 'dev'
8+
pull_request:
9+
branches:
10+
- 'main'
11+
12+
jobs:
13+
composer-test-suite:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- name: Checkout
17+
uses: actions/checkout@v4
18+
- name: Composer install
19+
run: |
20+
composer install -n --prefer-dist
21+
composer validate
22+
- name: phpcs checks
23+
run: |
24+
./vendor/bin/phpcs
25+
26+
drupal-test-suite:
27+
runs-on: ubuntu-latest
28+
steps:
29+
- name: Create full set of envvars
30+
uses: FranzDiebold/github-env-vars-action@v2
31+
- name: Checkout
32+
uses: actions/checkout@v4
33+
with:
34+
repository: lagoon-examples/drupal-base
35+
path: drupal-base
36+
ref: main
37+
- name: Report versions
38+
run: |
39+
docker version
40+
docker compose version
41+
node -v
42+
yarn -v
43+
- name: Add drupal-integrations override
44+
working-directory: drupal-base
45+
run: |
46+
composer config repositories.amazeeio/drupal_integrations '{"type": "github", "url": "http://github.com/amazeeio/drupal-integrations"}'
47+
composer config github-oauth.github.com ${{ secrets.GITHUB_TOKEN }}
48+
composer config platform.php 8.3.1
49+
composer require --no-install amazeeio/drupal_integrations:dev-${{ env.CI_ACTION_REF_NAME_SLUG }}
50+
- name: Pull all images
51+
working-directory: drupal-base
52+
run: |
53+
docker compose pull --ignore-pull-failures
54+
- name: Install test harness
55+
working-directory: drupal-base
56+
run: |
57+
yarn add leia-parser mocha chai@4 command-line-test
58+
- name: Generate test files
59+
working-directory: drupal-base
60+
run: |
61+
yarn leia "TESTING*.md" test -r 2 -s 'Start up tests' -t 'Verification commands' -c 'Destroy tests' --split-file
62+
- name: Run docker compose tests
63+
working-directory: drupal-base
64+
env:
65+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
66+
run: |
67+
yarn mocha --timeout 900000 test/*compose*.func.js

0 commit comments

Comments
 (0)