Question

Are there any unit testing solutions for Flex? or actionscript 3?

If so, what are their features? Any UI testing abilities? Functional testing? Any pointers, examples, libraries or tools that you can share?

Was it helpful?

Solution

I just found fluint, and it was a great unit testing library, better than both Flexunit and ASUnit imho. It handles asynchronous testing really nice.

OTHER TIPS

FlexUnit is pretty awesome - http://opensource.adobe.com/wiki/display/flexunit/FlexUnit

Also ASUnit - http://asunit.org

They are both pretty similiar and both haven taken quite a bit from frameworks like JUnit.

FlexMonkey (http://code.google.com/p/flexmonkey/) although I haven't used it myself seems to do UI unit testing.

I can confirm that FlexMonkey indeed does UI unit testing. It provides record/playback of UI interactions and generates FlexUnit test cases.

Check it out at http://flexmonkey.googlecode.com

I would recommend FlexUnit, too... and you also have a look at Visual FlexUnit.
A few days before I found the RIATest-Tool, but I haven't tried it yet.

I'd recommend fluint simply due to it having a more active developer base (and it's improved support of testing asynchronous code). Also, if you are after mocking/stubs there is asmock (a dynamic mocking framework) and mock-as3 (a static mocking framework).

For asynchronous unit testing dpUint is pretty useful. However FlexUnit is the way to go, if you wish to integrate unit testing with a Maven build. Asynchronous testing (e.g. Cairngorm events) can also be done with FlexUnit, but is not as elegant as with dpUint.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top