I've used mxUnit to test Transfer based applications before, for sure... It sounds like you are doing something weird in your folder set up?
How are your folders arranged? Mark On Sat, Sep 12, 2009 at 6:51 AM, Scott Brady <[email protected]> wrote: > > Has anyone successfully been able to use MXUnit in an application that > is also using Transfer? Or, more specifically, used MXUnit to test > transfer objects? > > I'm having issues where the MXUnit tests will only work if the > application itself has used a specific transfer object first. > > I'll see if I can explain, though it's a bit confusing (to me). > > The transfer table definitions all have a decorator (either a standard > "Base Decorator" or their own decorator [that will extend the > BaseDecorator]). > The application puts the transfer object into the application scope. > The unit tests are in a subfolder with a separate Application.cfc (so > it shouldn't be sharing the Application scope). The transfer object > for the MXUnit tests are in the local scope. If I try to run a unit > test and the transfer object hadn't been "initialized" by the main > application, I get an error that it can't find the Decorator as > defined in the XML file. > > One thing that has complicated matters is that we have a number of > different applications on one server, so the "web root" isn't the main > web root on the machine. So, I've had to set up the transfer folder > in the main web root, and set up a CF mapping called "transfer" that > points to that folder. > > I've tried using a mapping for my application that I use for the > decorators (so, it would be: > decorator="appMapping.com.myApp.BaseDecorator" ), but when I had that, > I would get an error from the Transfer code (usually the Remoting > factory) that a passed in argument wasn't of type > "transfer.com.Transfer" -- because the type was really > "appMapping.transfer.com.Transfer" > > So, I doubt that was very clear, so feel free to ask me for > clarification if it's not. > > Thanks! > > Scott > -- > ----------------------------------------- > Scott Brady > http://www.scottbrady.net/ > > > > -- E: [email protected] T: http://www.twitter.com/neurotic W: www.compoundtheory.com --~--~---------~--~----~------------~-------~--~----~ Before posting questions to the group please read: http://groups.google.com/group/transfer-dev/web/how-to-ask-support-questions-on-transfer You received this message because you are subscribed to the Google Groups "transfer-dev" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/transfer-dev?hl=en -~----------~----~----~----~------~----~------~--~---
