View unanswered posts | View active topics



Reply to topic  [ 1 post ] 
Observation:asUnit 
Author Message
Member

Joined: Sat Feb 24, 2007 9:12 pm
Posts: 19
"asunit.runner.BaseTestRunner.trace" works very well for asUnit+FD3.

Image

    2-Add the asUnit framework to global classpath (found in wherevererYouInstalledAsUnit/framework/as25 OR as3 folder)
    3-Create a new Project
    4-set the Custom Trace Function option in the project/properties/compiler options to "asunit.runner.BaseTestRunner.trace"


There may be a bug there since the "Custom Trace Function" field is empty even a value is set.

Unfortunately I have no Idea about the XUL UI since it crashes instantly on my vista. I'm writing the whole cases myself. :roll:
Rolling Eyes

IMO it should be very easy to add a third "Unit Test" option to debug/release combo. Project templates may contain a unitTest Folder which XUL UI will create its tests and a Main.as as test's entry point. I checked the settings files but couldn't find anything anything moddable. I guess it's hardcoded so I'm asking it as a feature. I think FD3 release must have this feature.

Edit: I managed to run the XUL UI. A shortcut on the desktop which points to: "C:\Program Files\AsUnit\xulrunner\xulrunner.exe" -app ../xului/application.ini did the trick. However I found that the XUL UI does nothing fancy but finding the classes that extend TestCase and build the necessary test classes. Again not a big job to add to FD3 :twisted:

Edit2: I found these two very good tutorials about the asUnit FW:
Part One: http://timbeynart.com/docs/ASUnit_Part1.pdf
Part Two: http://timbeynart.com/docs/ASUnit_Part2.pdf

Async testing is done in a much simpler manner than I thought. You simply override the run method not to run the test. Instead you add super.run() to the async method of your testCase. However a seperate TestCase must be created for each async method.

I'd do a plugin but I'm leaving in a week for military duty and hope someone finds this info useful when I'm dealing with potatoes.


Tue May 06, 2008 8:04 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 1 post ] 

Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software for PTF.