ColdBox Framework Forums Notification: Post to Using getPlugin() in cfcUnit creates error with coldbox controller (coldspring)

Title: RE: Using getPlugin() in cfcUnit creates error with coldbox controller (coldspring)
Thread: Using getPlugin() in cfcUnit creates error with coldbox controller (coldspring)
Forum: Need Help?
Conference: ColdBox
User: prentice Hi Luis,

I played around with it, but could not get it to work. So instead,
I've attached a sample app to show you what I mean.

For the sample app, I
generated a new app using the ant build in the coldbox dist called TestApp.
Then I added a TestModel.cfc in the /model/ directory as a test. I created a
method as a test, then a getter/setter for coldspring to pass in references to
the coldbox controller.

After this, I created the coldspring.xml.cfm to
have three declarations needed to pass in the coldbox controller to my

  <bean id="TestModel"
class="TestApp.model.TestModel" singleton="false">
      <ref bean="ColdBoxController" />

  <bean id="ColdBoxFactory"
class="coldbox.system.extras.ColdboxFactory" />
  <!-- coldbox controller -->
<bean id="ColdBoxController" factory-bean="ColdBoxFactory"
factory-method="getColdBox" />

I then modified the
general.dspHome event to get TestModel from the ioc plugin to make sure
everything's working properly:

  <cffunction name="dspHome"
access="public" returntype="void" output="false">
    <cfargument name="Event"
    <!--- Do Your Logic Here to
prepare a view --->
    <cfset Event.setValue("welcomeMessage","Welcome to
    <cfset Event.setValue("testModel",
getPlugin("ioc").getBean("TestModel")) />
    <!--- Set the View To Display,
after Logic --->
    <cfset Event.setView("home")>
When all this is done, I ran the unit test in the unittests/ directory (which is
the same as what coldbox generates for me, except I moved it out of /handlers/),
and that's when I get the same error as before.

I am very confused as to what
causes this error. If I remove all references to the coldbox controller in the
coldspring config, or if I don't use it at all (as in no reference to it in the
coldspring config), I don't get any errors. The moment I do, the error popups
during the unit test.