I got all my unit tests running fine on my local machine but I had a few issues getting them to work on the build server.
The first problem was that ant task was looking for c:\windows, the 2003 windows directory is c:\winnt.
A change to WindowsSWFLauncher.java fixed this:
private final String localTrustedDirectory = System.getenv( "windir" ) + "\\system32\\Macromed\\Flash\\FlashPlayerTrust\\";
the next problem was that the FlashPlayerTrust directory didn't exist so I had to create it myself on the build server. (ant task should probably do this if it doesn't exist but my java skills aren't up to that!).
At this point the runners got built and the trust file was created but the ant task timed out. If I ran the swf myself on the build server it launched but no tests ran. I manually created a trust file that trusted my whole deploy directory. The runners then launched ok and all reports got built.
I think the reason the trust file didn't work is because the file location in the ant task generated cfg file is:
when it should be
I imagine that this would be a fairly simple problem to fix.
@Roaders - Thanks for the footwork on this. I'll get the suggested fix into a patch and off to Mike. Unforunately, the path that's being written to the local trust file involves a fix for the Ant task to handle absoluate path conversion for the SWF path that's passed in the SWF attribute. The way we're launching the flash player on the Mac has proven to make this promblematic, so we haven't implemented the fix yet. When it's in place though, the absolute path to the SWF should show up correctly in the file. I'm gonna look into the FP security spec as well and see if we can grant the entire directory holding the TestRunner.swf local trust or not. Thanks again for the help, hopefully this weekend I can dive in.
You can grant access for a whole directory, it grants access for subdirectories as well. This is how I have got it working on my machine and on the build server.