Skip to content

Commit

Permalink
Apply cfformat changes
Browse files Browse the repository at this point in the history
  • Loading branch information
lmajano authored and github-actions[bot] committed Sep 7, 2024
1 parent a862397 commit d9a1d19
Showing 1 changed file with 15 additions and 7 deletions.
22 changes: 15 additions & 7 deletions system/runners/UnitRunner.cfc
Original file line number Diff line number Diff line change
Expand Up @@ -425,7 +425,7 @@ component
/**
* Retrieve the testing methods/specs from a given target.
*
* @target The target to get the methods from
* @target The target to get the methods from
* @testResults The test results object
*
* @return An array of method specs
Expand All @@ -438,18 +438,26 @@ component
for ( var thisMethod in methodArray ) {
// only valid functions and test functions allowed
if (
( isCustomFunction( arguments.target[ thisMethod ] ) || isClosure( arguments.target[ thisMethod ] ) )
(
isCustomFunction( arguments.target[ thisMethod ] ) || isClosure(
arguments.target[ thisMethod ]
)
)
&&
isValidTestMethod( thisMethod, arguments.target )
) {
// Build the spec data packet
var specMD = getMetadata( arguments.target[ thisMethod ] );
var spec = {
"id" : hash( specMD.name ),
"name" : specMD.name,
"hint" : ( structKeyExists( specMD, "hint" ) ? specMD.hint : "" ),
"skip" : ( structKeyExists( specMD, "skip" ) ? ( len( specMD.skip ) ? specMD.skip : true ) : false ),
"focused" : ( structKeyExists( specMD, "focused" ) ? ( len( specMD.focused ) ? specMD.focused : true ) : false ),
"id" : hash( specMD.name ),
"name" : specMD.name,
"hint" : ( structKeyExists( specMD, "hint" ) ? specMD.hint : "" ),
"skip" : (
structKeyExists( specMD, "skip" ) ? ( len( specMD.skip ) ? specMD.skip : true ) : false
),
"focused" : (
structKeyExists( specMD, "focused" ) ? ( len( specMD.focused ) ? specMD.focused : true ) : false
),
"labels" : ( structKeyExists( specMD, "labels" ) ? listToArray( specMD.labels ) : [] ),
"order" : ( structKeyExists( specMD, "order" ) ? listToArray( specMD.order ) : index++ ),
"expectedException" : (
Expand Down

0 comments on commit d9a1d19

Please sign in to comment.