kanbanworkflowstimelinescrumrubyroadmapproject-planningproject-managementopenprojectangularissue-trackerifcgantt-chartganttbug-trackerboardsbcf
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
87 lines
2.7 KiB
87 lines
2.7 KiB
name: Core/Test
|
|
# https://securitylab.github.com/research/github-actions-preventing-pwn-requests
|
|
on:
|
|
push:
|
|
branches:
|
|
- dev
|
|
- release/*
|
|
paths-ignore:
|
|
- 'docs/**'
|
|
- 'help/**'
|
|
pull_request:
|
|
types: [opened, reopened, synchronize]
|
|
paths-ignore:
|
|
- 'docs/**'
|
|
- 'help/**'
|
|
|
|
jobs:
|
|
danger:
|
|
if: github.repository == 'opf/openproject'
|
|
runs-on: [ubuntu-latest]
|
|
timeout-minutes: 10
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- uses: danger/danger@master
|
|
env:
|
|
DANGER_GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
units:
|
|
name: Units
|
|
if: github.repository == 'opf/openproject'
|
|
runs-on: [self-hosted-autoscale]
|
|
timeout-minutes: 30
|
|
env:
|
|
CI_CACHE_PATH: "/tmp/cache"
|
|
CI_RETRY_COUNT: 3
|
|
LOCAL_DEV_CHECK: 1
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: cache
|
|
uses: actions/cache@v2
|
|
with:
|
|
path: /tmp/cache
|
|
key: ${{ runner.os }}-core-tests-units-${{ hashFiles('**/Gemfile.lock') }}
|
|
restore-keys: |
|
|
${{ runner.os }}-core-tests-units-
|
|
${{ runner.os }}-core-tests-
|
|
- name: test
|
|
run: |
|
|
docker-compose -f docker-compose.ci.yml build ci
|
|
docker-compose -f docker-compose.ci.yml run ci setup-tests run-units
|
|
- name: cleanup
|
|
if: ${{ always() }}
|
|
run: |
|
|
docker-compose -f docker-compose.ci.yml down --remove-orphans -t 10
|
|
sudo chown -R $(whoami):$(id -ng) $CI_CACHE_PATH
|
|
features:
|
|
name: Features
|
|
if: github.repository == 'opf/openproject'
|
|
runs-on: [self-hosted-autoscale]
|
|
timeout-minutes: 60
|
|
env:
|
|
CI_CACHE_PATH: "/tmp/cache"
|
|
LOCAL_DEV_CHECK: 1
|
|
CI_RETRY_COUNT: 3
|
|
OPENPROJECT_ENABLE_CAPYBARA_SCREENSHOT_S3_UPLOADS: true
|
|
AWS_ACCESS_KEY_ID: "${{ secrets.CAPYBARA_AWS_ACCESS_KEY_ID }}"
|
|
AWS_SECRET_ACCESS_KEY: "${{ secrets.CAPYBARA_AWS_SECRET_ACCESS_KEY }}"
|
|
AWS_REGION: "eu-west-1"
|
|
S3_BUCKET_NAME: "openproject-ci-public-logs"
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: cache
|
|
uses: actions/cache@v2
|
|
with:
|
|
path: /tmp/cache
|
|
key: ${{ runner.os }}-core-tests-features-${{ hashFiles('**/Gemfile.lock') }}
|
|
restore-keys: |
|
|
${{ runner.os }}-core-tests-features-
|
|
${{ runner.os }}-core-tests-
|
|
- name: test
|
|
run: |
|
|
docker-compose -f docker-compose.ci.yml build ci
|
|
docker-compose -f docker-compose.ci.yml run ci setup-tests run-features
|
|
- name: cleanup
|
|
if: ${{ always() }}
|
|
run: |
|
|
docker-compose -f docker-compose.ci.yml down --remove-orphans -t 10
|
|
sudo chown -R $(whoami):$(id -ng) $CI_CACHE_PATH
|
|
|