-
-
Notifications
You must be signed in to change notification settings - Fork 7
58 lines (50 loc) · 1.64 KB
/
tests.yml
File metadata and controls
58 lines (50 loc) · 1.64 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
name: Test Suites
# We are a reusable Workflow only
on:
workflow_call:
secrets:
SLACK_WEBHOOK_URL:
required: true
jobs:
tests:
name: Tests
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v6
- name: Setup Java
uses: actions/setup-java@v5
with:
distribution: "temurin"
java-version: "11"
- name: Setup CommandBox CLI
uses: Ortus-Solutions/setup-commandbox@v2.0.1
# Not Needed in this module
#- name: Setup Environment For Testing Process
# run: |
# # Setup .env
# touch .env
# # ENV
# printf "DB_HOST=localhost\n" >> .env
# printf "DB_DATABASE=mydatabase\n" >> .env
# printf "DB_DRIVER=MySQL\n" >> .env
# printf "DB_USER=${{ env.DB_USER }}\n" >> .env
# printf "DB_PASSWORD=${{ env.DB_PASSWORD }}\n" >> .env
# printf "DB_CLASS=com.mysql.cj.jdbc.Driver\n" >> .env
# printf "DB_BUNDLEVERSION=8.0.19\n" >> .env
# printf "DB_BUNDLENAME=com.mysql.cj\n" >> .env
- name: Install Test Harness Dependencies
run: |
box install
- name: Run Tests
run: |
# Create the CommandBox modules folder, for some reason it is not created
rm -Rf ~/.CommandBox/cfml/modules/coldbox-cli
mkdir -p ~/.CommandBox/cfml/modules
# Link up the module so we can do testing!
box link --force
# Test
box task run taskfile=build/Build target="runTests"
- name: Failure Logs
if: failure()
run: cat `box system-log`