Skip to content

Commit

Permalink
BAH-1231 | Add validate PR workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
NoorShiuli committed Oct 6, 2022
1 parent e3a11e5 commit a66643f
Showing 1 changed file with 61 additions and 0 deletions.
61 changes: 61 additions & 0 deletions .github/workflows/validate_pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: Validate PR
on:
pull_request:
branches: [ master ]

paths-ignore:
- '**.md'

jobs:
build-package:
name: Test and Package
runs-on: ubuntu-latest

services:
clinlims:
image: postgres:9.4
env:
POSTGRES_DB: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_USER: postgres
ports:
- 5432:5432
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- uses: actions/checkout@v2
- name: Setup Java 7 for ant
uses: actions/setup-java@v2
with:
distribution: 'zulu'
java-version: '7'
- name: Setup Ruby 2.3
uses: ruby/setup-ruby@v1
with:
ruby-version: 2.3
- name: Install Compass
run: gem install compass
- name: Install Ant 1.9
run: |
mkdir /tmp/ant
cd /tmp/ant
wget https://dlcdn.apache.org//ant/binaries/apache-ant-1.9.16-bin.tar.gz
tar -zxf apache-ant-1.9.16-bin.tar.gz
echo "ANT_HOME=/tmp/ant/apache-ant-1.9.16" >> $GITHUB_ENV
echo "/tmp/ant/apache-ant-1.9.16/bin" >> $GITHUB_PATH
- name: Package
run: ant dist
- name: Setup DB
env:
PGPASSWORD: postgres
run: ant setupDB
- name: Set up JDK 1.8
uses: actions/setup-java@v1
with:
java-version: 1.8
- name: Run tests
run: ant test test-only

0 comments on commit a66643f

Please sign in to comment.