Skip to content

Commit 31b01be

Browse files
committed
new templates
1 parent 0856b26 commit 31b01be

4 files changed

Lines changed: 40 additions & 15 deletions

File tree

changelog.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
99

1010
## [Unreleased]
1111

12+
### Added
13+
14+
- New template updates for CFML and BoxLang
15+
1216
## [1.7.0] - 2025-08-06
1317

1418
### Added

templates/bx/tests/Application.bx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
* to a root application. Usually you mimic your application's Application.bx settings here.
77
*/
88
class {
9+
// Harness name
910
this.name = "My Test Harness";
10-
1111
// The mapping to easily access the tests
1212
this.mappings[ "/tests" ] = getDirectoryFromPath( getCurrentTemplatePath() );
1313
// The mapping to easily access the root application usually the parent folder

templates/bx/tests/runner.bxm

Lines changed: 23 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,23 +3,34 @@
33
<bx:param name="url.directory" default="tests.specs">
44
<bx:param name="url.recurse" default="true" type="boolean">
55
<bx:param name="url.bundles" default="">
6-
<bx:param name="url.labels" default="">
7-
<bx:param name="url.excludes" default="">
8-
<bx:param name="url.reportpath" default="#expandPath( "/tests/results" )#">
9-
<bx:param name="url.propertiesFilename" default="TEST.properties">
6+
<bx:param name="url.labels" default="">
7+
<bx:param name="url.excludes" default="">
8+
<bx:param name="url.reportpath" default="#expandPath( "/tests/results" )#">
9+
<bx:param name="url.propertiesFilename" default="TEST.properties">
1010
<bx:param name="url.propertiesSummary" default="false" type="boolean">
11-
<bx:param name="url.editor" default="vscode">
12-
<bx:param name="url.bundlesPattern" default="*Spec*.cfc|*Test*.cfc|*Spec*.bx|*Test*.bx">
11+
<bx:param name="url.editor" default="vscode">
12+
<bx:param name="url.bundlesPattern" default="*Spec*.cfc|*Test*.cfc|*Spec*.bx|*Test*.bx">
13+
14+
<!--- Streaming mode: streams results via Server-Sent Events (SSE) for real-time progress --->
15+
<bx:param name="url.streaming" default="false" type="boolean">
16+
<bx:param name="url.dryRun" default="false" type="boolean">
1317

1418
<!--- Code Coverage requires FusionReactor --->
15-
<bx:param name="url.coverageEnabled" default="false">
16-
<bx:param name="url.coveragePathToCapture" default="#expandPath( '/root' )#">
17-
<bx:param name="url.coverageWhitelist" default="">
18-
<bx:param name="url.coverageBlacklist" default="/testbox,/coldbox,/tests,/modules,Application.cfc,/index.cfm,Application.bx,/index.bxm">
19+
<bx:param name="url.coverageEnabled" default="false" type="boolean">
20+
<bx:param name="url.coveragePathToCapture" default="#expandPath( '/root' )#">
21+
<bx:param name="url.coverageWhitelist" default="">
22+
<bx:param name="url.coverageBlacklist" default="/testbox,/coldbox,/tests,/modules,Application.cfc,/index.cfm,Application.bx,/index.bxm">
1923
<!---<bx:param name="url.coverageBrowserOutputDir" default="#expandPath( '/tests/results/coverageReport' )#">--->
2024
<!---<bx:param name="url.coverageSonarQubeXMLOutputPath" default="#expandPath( '/tests/results/SonarQubeCoverage.xml' )#">--->
2125
<!--- Enable batched code coverage reporter, useful for large test bundles which require spreading over multiple testbox run commands. --->
2226
<!--- <bx:param name="url.isBatched" default="false"> --->
2327

24-
<!--- Include the TestBox HTML Runner --->
25-
<bx:include template="/testbox/system/runners/HTMLRunner.cfm" >
28+
29+
<!--- Include the appropriate runner based on streaming mode --->
30+
<cfif url.streaming && !url.dryRun>
31+
<!--- Stream results in real-time via SSE --->
32+
<bx:include template="/testbox/system/runners/StreamingRunner.cfm" >
33+
<cfelse>
34+
<!--- Traditional batch results --->
35+
<bx:include template="/testbox/system/runners/HTMLRunner.cfm" >
36+
</cfif>

templates/cfml/tests/runner.cfm

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,10 @@
1212
<cfparam name="url.editor" default="vscode">
1313
<cfparam name="url.bundlesPattern" default="*Spec*.cfc|*Test*.cfc|*Spec*.bx|*Test*.bx">
1414

15+
<!--- Streaming mode: streams results via Server-Sent Events (SSE) for real-time progress --->
16+
<cfparam name="url.streaming" default="false" type="boolean">
17+
<cfparam name="url.dryRun" default="false" type="boolean">
18+
1519
<!--- Code Coverage requires FusionReactor --->
1620
<cfparam name="url.coverageEnabled" default="true">
1721
<cfparam name="url.coveragePathToCapture" default="#expandPath( '/root' )#">
@@ -22,5 +26,11 @@
2226
<!--- Enable batched code coverage reporter, useful for large test bundles which require spreading over multiple testbox run commands. --->
2327
<!--- <cfparam name="url.isBatched" default="false"> --->
2428

25-
<!--- Include the TestBox HTML Runner --->
26-
<cfinclude template="/testbox/system/runners/HTMLRunner.cfm" >
29+
<!--- Include the appropriate runner based on streaming mode --->
30+
<cfif url.streaming && !url.dryRun>
31+
<!--- Stream results in real-time via SSE --->
32+
<cfinclude template="/testbox/system/runners/StreamingRunner.cfm">
33+
<cfelse>
34+
<!--- Traditional batch results --->
35+
<cfinclude template="/testbox/system/runners/HTMLRunner.cfm">
36+
</cfif>

0 commit comments

Comments
 (0)