Local testing in CFML

Testing correct solutions locally gives quite confusing output, with a GLOBAL BUNDLE EXCEPTION message displaying over several lines in an eye-catching bright red font. The culprit appears to be a file SolutionTest.cfc that downloads with every exercise. As far as I can tell, this is part of the CI suite to check that all the exemplar solutions are working correctly on GitHub (paired with a Solution.cfc for each exercise). It should not be given to students, and deleting this file locally makes everything work correctly.

exercism download already knows not to give the student Solution.cfc. Can we also tell it to withhold SolutionTest.cfc? It looks like this, so loading Solution.cfc is all it does:

component extends="DifferenceOfSquaresTest" {

	function beforeAll(){
	  SUT = createObject( 'Solution' );


The reason Solution.cfc is not downloaded is because it is listed as the example file in the .meta/config.json file. What I would suggest needs to happen is:

  • Move all Solution.cfc files to .meta/Example.cfc
  • Move all SolutionTest.cfc files to .meta/ExampleTest.cfc
  • Update the .meta/config.json file’s example key to [".meta/Example.cfc", ".meta/ExampleTest.cfc"]

Addressed in PR #180

I think this is the last (semi-)urgent fix for this track.

1 Like