Hi Chaps,
I’m getting myself confused here so hopefully you guys will point out the obvious mistake I’m making
Here’s what I’m doing:
- setting up Testbox for a legacy application (no frameworks) on ColdFusion 10 that has no test suite
- I have download and extracted Testbox 2.1.0 to a non web accessible location [~/projects/coldfusion/testbox-2_1_0/]
- So I have something like:
~/projects/coldfusion/testbox-2_1_0/testbox-2_1_0/
~/projects/coldfusion/testbox-2_1_0/testbox-2_1_0/testbox/
inside the testbox directory I have:
apidocs/
test-browser/
license.txt
test-harness/
mockbox.md
test-runner/
readme.md
testbox-2.1.0+00008-201411122116
system/
tests/
In ColdFusion Administrator I have created mapping named “testbox” to “/Users/johnwhish/projects/coldfusion/testbox-2_1_0/testbox”
In my webroot I have created a simple testrunner:
<cfset r = new testbox.system.TestBox(directory={ mapping=“unittests”, recurse=true }, reporter=“simple”)>
#r.run()#
When I run that I get:
Could not find the ColdFusion component or interface testbox.system.testing.BaseSpec.
Ensure that the name is correct and that the component or interface exists.
The error occurred in /Users/johnwhish/projects/coldfusion/testbox-2_1_0/testbox/system/TestBox.cfc: line 371
Called from /Users/johnwhish/projects/coldfusion/testbox-2_1_0/testbox/system/TestBox.cfc: line 346
Called from /Users/johnwhish/projects/coldfusion/testbox-2_1_0/testbox/system/TestBox.cfc: line 165
Called from /Users/johnwhish/projects/coldfusion/testbox-2_1_0/testbox/system/TestBox.cfc: line 96
Looking in the “/Users/johnwhish/projects/coldfusion/testbox-2_1_0/testbox/system/” directory there isn’t a “testing” directory. BaseSpec has a path of “/Users/johnwhish/projects/coldfusion/testbox-2_1_0/testbox/system/”. So I’m not sure where that “testing” part of “testbox.system.testing.BaseSpec” is being picked up from.
I’ve used Testbox before so not quite sure why I’m having issues today - probably something dumb I’m doing but I just can’t spot it at the moment!
Thanks
John