Skip to content

Commit d02f622

Browse files
committed
v3.0.0
2 parents af11a48 + de45ec7 commit d02f622

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

77 files changed

+6106
-1823
lines changed
Lines changed: 8 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,20 @@
11
{
2-
"systemErr":"System",
3-
"systemOut":"System",
2+
"adminPassword" : "coldbox",
43
"componentCacheEnabled":false,
5-
"saveClassFiles":false,
4+
"postParametersLimit" : 200,
65
"robustExceptionEnabled":true,
7-
"adminPassword" : "coldbox",
6+
"saveClassFiles":false,
7+
"systemErr":"System",
8+
"systemOut":"System",
9+
"thistimezone":"UTC",
10+
"whitespaceManagement":"white-space-pref",
811
"debuggingEnabled":true,
912
"debuggingReportExecutionTimes":false,
1013
"disableInternalCFJavaComponents":false,
1114
"inspectTemplate":"always",
1215
"requestTimeout":"0,0,0,90",
13-
"thistimezone":"UTC",
14-
"whitespaceManagement":"white-space-pref",
15-
"postParametersLimit" : 200,
1616
"datasources":{
1717
"cbsecurity":{
18-
"allowAlter":true,
19-
"allowCreate":true,
20-
"allowDelete":true,
21-
"allowDrop":true,
22-
"allowGrant":true,
23-
"allowInsert":true,
24-
"allowRevoke":true,
25-
"allowSelect":true,
26-
"allowUpdate":true,
2718
"bundleName": "${DB_BUNDLENAME}",
2819
"bundleVersion": "${DB_BUNDLEVERSION}",
2920
"blob":"true",
@@ -44,4 +35,4 @@
4435
"validate":"false"
4536
}
4637
}
47-
}
38+
}

.cfformat.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,9 @@
66
"array.multiline.leading_comma.padding": true,
77
"array.multiline.leading_comma": false,
88
"alignment.consecutive.assignments": true,
9-
"alignment.consecutive.properties": false,
9+
"alignment.consecutive.properties": true,
1010
"alignment.consecutive.params": true,
11+
"alignment.doc_comments" : true,
1112
"brackets.padding": true,
1213
"comment.asterisks": "align",
1314
"binary_operators.padding": true,
@@ -41,7 +42,7 @@
4142
"keywords.spacing_to_block": "spaced",
4243
"keywords.spacing_to_group": true,
4344
"keywords.empty_group_spacing": false,
44-
"max_columns": 100,
45+
"max_columns": 115,
4546
"metadata.multiline.element_count": 3,
4647
"metadata.multiline.min_length": 50,
4748
"method_call.chain.multiline" : 3,
@@ -59,4 +60,4 @@
5960
"struct.multiline.element_count": 2,
6061
"struct.multiline.min_length": 60,
6162
"tab_indent": true
62-
}
63+
}

.cflintrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,4 +59,4 @@
5959
"parameters": {
6060
"TooManyFunctionsChecker.maximum" : 20
6161
}
62-
}
62+
}
File renamed without changes.

.github/FUNDING.YML

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
patreon: ortussolutions

.github/workflows/ci.yml

Lines changed: 8 additions & 132 deletions
Original file line numberDiff line numberDiff line change
@@ -15,124 +15,9 @@ jobs:
1515
# Tests First baby! We fail, no build :(
1616
#############################################
1717
tests:
18-
name: Tests
19-
runs-on: ubuntu-20.04
20-
env:
21-
DB_USER: root
22-
DB_PASSWORD: root
23-
strategy:
24-
fail-fast: false
25-
matrix:
26-
cfengine: [ "lucee@5", "adobe@2016", "adobe@2018", "adobe@2021" ]
27-
steps:
28-
- name: Checkout Repository
29-
uses: actions/checkout@v2
30-
31-
- name: Setup Java
32-
uses: actions/setup-java@v2
33-
with:
34-
distribution: "adopt"
35-
java-version: "11"
36-
37-
- name: Setup Database and Fixtures
38-
run: |
39-
sudo /etc/init.d/mysql start
40-
# Create Database
41-
mysql -u${{ env.DB_USER }} -p${{ env.DB_PASSWORD }} -e 'CREATE DATABASE cbsecurity;'
42-
# Import Database
43-
mysql -u${{ env.DB_USER }} -p${{ env.DB_PASSWORD }} < test-harness/tests/resources/cbsecurity.sql
44-
45-
- name: Setup Environment For Testing Process
46-
working-directory: ./test-harness
47-
run: |
48-
# Setup .env
49-
touch .env
50-
# ENV
51-
printf "DB_HOST=localhost\n" >> .env
52-
printf "DB_USER=${{ env.DB_USER }}\n" >> .env
53-
printf "DB_PASSWORD=${{ env.DB_PASSWORD }}\n" >> .env
54-
printf "DB_CLASS=com.mysql.cj.jdbc.Driver\n" >> .env
55-
printf "DB_BUNDLEVERSION=8.0.19\n" >> .env
56-
printf "DB_BUNDLENAME=com.mysql.cj\n" >> .env
57-
58-
- name: Cache CommandBox Dependencies
59-
uses: actions/cache@v1
60-
if: ${{ true }}
61-
with:
62-
path: ~/.CommandBox/artifacts
63-
key: ${{ runner.OS }}-commandbox-cache-${{ hashFiles( 'box.json' ) }}-${{ hashFiles( 'test-harness/box.json' ) }}
64-
restore-keys: |
65-
${{ runner.OS }}-commandbox-cache-${{ hashFiles( 'box.json' ) }}-${{ hashFiles( 'test-harness/box.json' ) }}
66-
67-
- name: Setup CommandBox
68-
uses: elpete/[email protected]
69-
70-
- name: Install Test Harness Dependencies
71-
working-directory: ./test-harness
72-
run: |
73-
box install
74-
75-
- name: Start ${{ matrix.cfengine }} Server
76-
working-directory: ./test-harness
77-
run: box server start serverConfigFile="server-${{ matrix.cfengine }}.json" --noSaveSettings --debug
78-
79-
- name: CFPM Setup
80-
if: ${{ matrix.cfengine == 'adobe@2021' }}
81-
working-directory: ./test-harness
82-
run: box run-script install:2021
83-
84-
- name: Prime ${{ matrix.cfengine }} server
85-
working-directory: ./test-harness
86-
run: curl http://127.0.0.1:60299
87-
88-
- name: Run Tests
89-
working-directory: ./test-harness
90-
run: |
91-
mkdir tests/results
92-
box package set testbox.runner="http://localhost:60299/tests/runner.cfm"
93-
box testbox run --verbose outputFile=tests/results/test-results outputFormats=json,antjunit
94-
95-
- name: Publish Test Results
96-
uses: EnricoMi/publish-unit-test-result-action@v1
97-
if: always()
98-
with:
99-
files: test-harness/tests/results/**/*.xml
100-
check_name: "${{ matrix.cfengine }} Test Results"
101-
102-
- name: Upload Test Results Artifacts
103-
if: always()
104-
uses: actions/upload-artifact@v2
105-
with:
106-
name: test-results-${{ matrix.cfengine }}
107-
path: |
108-
test-harness/tests/results/**/*
109-
110-
- name: Slack Notification
111-
if: failure()
112-
uses: rtCamp/action-slack-notify@v2
113-
env:
114-
SLACK_CHANNEL: coding
115-
SLACK_COLOR: ${{ job.status }} # or a specific color like 'green' or '#ff00ff'
116-
SLACK_ICON_EMOJI: ":bell:"
117-
SLACK_MESSAGE: '${{ env.MODULE_ID }} tests failed :cry:'
118-
SLACK_TITLE: ${{ env.MODULE_ID }} Tests For ${{ matrix.cfengine }} failed
119-
SLACK_USERNAME: CI
120-
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_URL }}
121-
122-
- name: Failure Debugging Info
123-
if: ${{ failure() }}
124-
working-directory: ./test-harness
125-
run: |
126-
box server log serverConfigFile="server-${{ matrix.cfengine }}.json"
127-
128-
- name: Upload Debugging Info To Artifacts
129-
if: ${{ failure() }}
130-
uses: actions/upload-artifact@v2
131-
with:
132-
name: Failure Debugging Info - ${{ matrix.cfengine }}
133-
path: |
134-
test-harness/.engine/**/logs/*
135-
test-harness/.engine/**/WEB-INF/cfusion/logs/*
18+
uses: ./.github/workflows/tests.yml
19+
secrets:
20+
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
13621

13722
#############################################
13823
# Build Module
@@ -143,27 +28,18 @@ jobs:
14328
runs-on: ubuntu-20.04
14429
steps:
14530
- name: Checkout Repository
146-
uses: actions/checkout@v2
31+
uses: actions/checkout@v3.2.0
14732
with:
14833
fetch-depth: 0
14934

15035
- name: Setup Java
151-
uses: actions/setup-java@v2
36+
uses: actions/setup-java@v3.9.0v2
15237
with:
153-
distribution: "adopt"
38+
distribution: "temurin"
15439
java-version: "11"
15540

156-
- name: Cache CommandBox Dependencies
157-
uses: actions/cache@v1
158-
if: ${{ true }}
159-
with:
160-
path: ~/.CommandBox/artifacts
161-
key: ${{ runner.OS }}-commandbox-cache-${{ hashFiles( 'box.json' ) }}-${{ hashFiles( 'test-harness/box.json' ) }}
162-
restore-keys: |
163-
${{ runner.OS }}-commandbox-cache-${{ hashFiles( 'box.json' ) }}-${{ hashFiles( 'test-harness/box.json' ) }}
164-
16541
- name: Setup CommandBox
166-
uses: elpete/setup-commandbox@v1.0.0
42+
uses: Ortus-Solutions/setup-commandbox@v2.0.1
16743
with:
16844
forgeboxAPIKey: ${{ secrets.FORGEBOX_TOKEN }}
16945

@@ -187,7 +63,7 @@ jobs:
18763
18864
- name: Upload Build Artifacts
18965
if: success()
190-
uses: actions/upload-artifact@v2
66+
uses: actions/upload-artifact@v3.1.1
19167
with:
19268
name: ${{ env.MODULE_ID }}
19369
path: |

.github/workflows/gh-release.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
# Publish Github Release
2+
name: Github Release
3+
4+
on:
5+
push:
6+
tags:
7+
- v[0-9]+.*
8+
9+
jobs:
10+
create-release:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/[email protected]
14+
- uses: taiki-e/[email protected]
15+
with:
16+
# Produced by the build/Build.cfc
17+
changelog: changelog.md
18+
env:
19+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/pr.yml

Lines changed: 8 additions & 93 deletions
Original file line numberDiff line numberDiff line change
@@ -12,108 +12,23 @@ on:
1212

1313
jobs:
1414
tests:
15-
name: Tests
16-
runs-on: ubuntu-20.04
17-
env:
18-
DB_USER: root
19-
DB_PASSWORD: root
20-
strategy:
21-
fail-fast: true
22-
matrix:
23-
cfengine: [ "lucee@5", "adobe@2016", "adobe@2018", "adobe@2021" ]
24-
steps:
25-
- name: Checkout Repository
26-
uses: actions/checkout@v2
27-
28-
- name: Setup Database and Fixtures
29-
run: |
30-
sudo /etc/init.d/mysql start
31-
mysql -u${{ env.DB_USER }} -p${{ env.DB_PASSWORD }} -e 'CREATE DATABASE cbsecurity;'
32-
mysql -u${{ env.DB_USER }} -p${{ env.DB_PASSWORD }} < test-harness/tests/resources/cbsecurity.sql
33-
34-
- name: Setup Java
35-
uses: actions/setup-java@v2
36-
with:
37-
distribution: "adopt"
38-
java-version: "11"
39-
40-
- name: Setup CommandBox
41-
uses: elpete/[email protected]
42-
43-
- name: Setup Environment For Testing Process
44-
working-directory: ./test-harness
45-
run: |
46-
# Setup .env
47-
touch .env
48-
# ENV
49-
printf "DB_HOST=localhost\n" >> .env
50-
printf "DB_USER=${{ env.DB_USER }}\n" >> .env
51-
printf "DB_PASSWORD=${{ env.DB_PASSWORD }}\n" >> .env
52-
printf "DB_CLASS=com.mysql.cj.jdbc.Driver\n" >> .env
53-
printf "DB_BUNDLEVERSION=8.0.19\n" >> .env
54-
printf "DB_BUNDLENAME=com.mysql.cj\n" >> .env
55-
56-
- name: Install Test Harness Dependencies
57-
working-directory: ./test-harness
58-
run: |
59-
box install
60-
61-
- name: Start ${{ matrix.cfengine }} Server
62-
working-directory: ./test-harness
63-
run: box server start serverConfigFile="server-${{ matrix.cfengine }}.json" --noSaveSettings --debug
64-
65-
- name: CFPM Setup
66-
if: ${{ matrix.cfengine == 'adobe@2021' }}
67-
working-directory: ./test-harness
68-
run: box run-script install:2021
69-
70-
- name: Prime ${{ matrix.cfengine }} server
71-
working-directory: ./test-harness
72-
run: curl http://127.0.0.1:60299
73-
74-
- name: Run Tests
75-
working-directory: ./test-harness
76-
run: |
77-
mkdir tests/results
78-
box package set testbox.runner="http://localhost:60299/tests/runner.cfm"
79-
box testbox run --verbose outputFile=tests/results/test-results outputFormats=json,antjunit
80-
81-
- name: Publish PR Test Reports
82-
uses: mikepenz/action-junit-report@v2
83-
with:
84-
report_paths: 'test-harness/tests/results/**/*.xml'
85-
check_name: "${{ matrix.cfengine }} Test Results"
86-
summary: true
87-
88-
- name: Failure Debugging Info
89-
if: ${{ failure() }}
90-
working-directory: ./test-harness
91-
run: |
92-
box server log serverConfigFile="server-${{ matrix.cfengine }}.json"
15+
uses: ./.github/workflows/tests.yml
16+
secrets:
17+
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }}
9318

19+
# Format PR
9420
format:
9521
name: Format
9622
runs-on: ubuntu-20.04
9723
steps:
9824
- name: Checkout Repository
99-
uses: actions/checkout@v2
25+
uses: actions/checkout@v3.2.0
10026

101-
- name: Setup Java
102-
uses: actions/setup-java@v2
27+
- uses: Ortus-Solutions/[email protected]
10328
with:
104-
distribution: "adopt"
105-
java-version: "11"
106-
107-
- name: Set Up CommandBox
108-
uses: elpete/[email protected]
109-
110-
- name: Install CFFormat
111-
run: box install commandbox-cfformat
112-
113-
- name: Run CFFormat
114-
run: box run-script format
29+
cmd: run-script format
11530

11631
- name: Commit Format Changes
11732
uses: stefanzweifel/git-auto-commit-action@v4
11833
with:
119-
commit_message: Apply cfformat changes
34+
commit_message: Apply cfformat changes

0 commit comments

Comments
 (0)