Running CFUnit in CFEclipse quick guide

As you might of heard CFUnit is now integrated into the beta build of CFEclipse. To bring you up-to-speed about CFUnit(incase you didn't know); CFUnit is a unit testing framework for ColdFusion, modelled after the popular JUnit framework. By building test units while creating your app you can ensure that your methods (cffunctions) and components overall behave as expected. If you are totally new to CFUnit you might want to check out the references at the end of this post.

So who is this guide for. Well nearly anyone who wants to get started with CFUnit within CFEclipse. For reference I am working on Eclipse 3.2.1 with CFEclipse 1.3 Beta RC2 1.2.9.7 and im gonna assume you've got both on your sytem. This guide doesn't really go into all the benefits of CFUnit (though by the end of this you should be able to seem them) so if you want more details afterwards check out the points of reference at the end.

Posted: 15-Jan-2007

View: 18635

Permalink: here

Comments

Hi Andy:

Great stuff.

The link CFEclipse 1.3 Beta RC2 1.2.9.7 site is also listed in Mark Drew's blog entry: http://www.markdrew.co.uk/blog/index.cfm/2007/1/13...

#1 Indy Nagpal
15/Jan/07 9:37 PM

Great article and really helpful setting up CfUnit real quick.

One minor thing: In first image, it shows URL as localhost.net.sourceforge.cfunit.framework Instead of localhost/net/sourceforge/cfunit/framework.

Cheers,
-Dipak

#2 Dipak
21/Jan/07 9:34 AM

I'm currently using CFEclipse 1.3 Final, and can not find this feature. Do you know if it was it removed?

#3 Louis Galipeau
30/Jan/07 2:31 PM

As with all betas some functions never make it into the final release. This is one of those. That's not to say it won't be there in the future so look out for it!

#4 Andy Jarrett
30/Jan/07 3:49 PM

Just wanted to say thanks for taking the time to this quick start guide. Very helpful to people just getting starting with CFUNIT.

Cheers

#5 jM
27/Sep/07 12:53 PM

> to this quick start guide.

Oops. "to post this quick start guide .." ;-)

#6 jM
27/Sep/07 12:55 PM

I have walked through this amazing guide for setting this up however, i have been running into major difficulty. I can run the tests via my browser, however, when I attempt to open the test files as he has done in the guide, it never works. in fact I am configured the exact same as Andy, i have cfm installed locally and the directories setup the exact same as instructed. when i go to use the cfunit module in cfeclipse all i see next to the runs: is runs: ---/--- and nothing displayed in the second box below.

Any help with this issue would be greatly appreciated and thank you for your time.

#7 chris
29/Oct/07 2:18 PM

Hi. I have the same problem as Chris. I followed the article a la lettre and I can't run my tests: --/-- is displayed at the "Run" section.

#8 Dilraj
11/Dec/07 1:11 AM

Same here. It works when browsing locally to the example test that comes with cfunit, but exactly following this guid doesn't do anything within eclipse.

Hopefully the author can take the time to look into this since I'm not able to get it working.

#9 Ron
12/Feb/08 8:00 AM

Same problems here as for Ron and others.
Would be nice to have CFUnit within Eclipse :)

#10 chlu
12/Feb/08 10:49 AM

To the people above getting the --/-- problem: For me that was related to what Dipak posted above about the screenshot being incorrect. The dots in the screenshot should be slashes. Changing this made the example work for me. Hope it works for your too.

#11 Illykai
02/Mar/08 2:19 AM

Thanks for the information. I am new to CFUnit but I'm gonna be diving into this starting tonight as I try to use it for my latest project at work.

#12 Ken Barrett
16/Jun/08 2:05 PM

I just now installed CFUnit, and am running into the same --/-- issue. I have altered the path to use / in CFEclipse, but it's still not working for me. Anyone have anything else for me to try?

#13 Gareth Arch
25/Jun/09 6:16 PM