Which remind me, isn't someone on the mood to add an UI for flexmojos test runner and to make it not fail if the socket server is no available?
That way people would be able to use TestRunner.swf outside flexmojos... VELO On Thu, May 20, 2010 at 3:49 PM, Eric Feminella <[email protected]>wrote: > You can do this by specifying a <testRunnerTemplate> in the configuration > block. > > For example: > </configuration> > <testRunnerTemplate>${project.build.testSourceDirectory}/${ > flex.testharness.name}.mxml</testRunnerTemplate> > </configuration> > > However, keep in mind the TestRunner you're using from the IDE will > not have references to the SocketReporter and ControlSocket. You will > need to add these as well as your Tests. > > Eric > > > On Thu, May 20, 2010 at 2:42 PM, Davis Ford > <[email protected]> wrote: > > I have a custom TestRunner.mxml that I use to run tests in Eclipse > > with. The test passes in that. Is there a way I can tell flexmojos > > to use that instead of creating its own TestRunner.swf on the fly? > > > > On Thu, May 20, 2010 at 2:16 PM, Marvin Froeder <[email protected]> > wrote: > >> Or you declare [ResourceBundle("bundleName")] onto a custom test runner > or > >> into you Test class. > >> > >> VELO > >> > >> On Thu, May 20, 2010 at 3:06 PM, Davis Ford < > [email protected]> > >> wrote: > >>> > >>> I have a UI FlexUnit4 test kind of like this: > >>> > >>> [BeforeClass] > >>> public static function beforeClass():void { > >>> ResourceManager.getInstance().localeChain=["en_US"]; > >>> } > >>> > >>> [Before(async,ui)] > >>> public function setUp():void { > >>> _renderer = new MyRenderer(); > >>> Async.proceedOnEvent(this, _renderer, > FlexEvent.CREATION_COMPLETE); > >>> UIImpersonator.addChild(_renderer); > >>> } > >>> > >>> [After(ui)] > >>> public function tearDown():void { > >>> UIImpersonator.removeChild(_renderer); > >>> _renderer = null; > >>> } > >>> > >>> [Test] > >>> public function verifyToolTipForExecInfo():void { > >>> etc... > >>> } > >>> > >>> > >>> The code that the test case tests ends up calling the ResourceManager > >>> itself to get a string: > >>> > >>> // code under test does this > >>> var s:String = ResourceManager.getInstance().getString("bundleName", > >>> "key"); > >>> > >>> When I run this test inside Eclipse in my own TestRunner.mxml > >>> application with the resource bundle metadata it works fine: > >>> > >>> <mx:Metadata> > >>> [ResourceBundle("bundleName")] > >>> </mx:Metadata> > >>> > >>> This file is located at > >>> src/main/resources/locales/en_US/bundleName.properties > >>> > >>> The test passes fine for me...but when I run it as: > >>> > >>> $ mvn clean test > >>> > >>> It fails because the string returned from getString() is always null, > >>> and I'm not sure why. Anyone have any clue / pointers on how to > >>> resolve this ? > >>> > >>> Thanks in advance, > >>> Davis > >>> > >>> -- > >>> You received this message because you are subscribed to the Google > >>> Groups "Flex Mojos" group. > >>> To post to this group, send email to [email protected] > >>> To unsubscribe from this group, send email to > >>> [email protected]<flex-mojos%[email protected]> > >>> For more options, visit this group at > >>> http://groups.google.com/group/flex-mojos > >>> > >>> http://flexmojos.sonatype.org/ > >> > >> -- > >> You received this message because you are subscribed to the Google > >> Groups "Flex Mojos" group. > >> To post to this group, send email to [email protected] > >> To unsubscribe from this group, send email to > >> [email protected]<flex-mojos%[email protected]> > >> For more options, visit this group at > >> http://groups.google.com/group/flex-mojos > >> > >> http://flexmojos.sonatype.org/ > >> > > > > > > > > -- > > Zeno Consulting, Inc. > > home: http://www.zenoconsulting.biz > > blog: http://zenoconsulting.wikidot.com > > p: 248.894.4922 > > f: 313.884.2977 > > > > -- > > You received this message because you are subscribed to the Google > > Groups "Flex Mojos" group. > > To post to this group, send email to [email protected] > > To unsubscribe from this group, send email to > > [email protected]<flex-mojos%[email protected]> > > For more options, visit this group at > > http://groups.google.com/group/flex-mojos > > > > http://flexmojos.sonatype.org/ > > > > > > -- > Eric Feminella | Software Architect, RIA | www.ericfeminella.com | > [email protected] | 609 558 1817 > > -- > You received this message because you are subscribed to the Google > Groups "Flex Mojos" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected]<flex-mojos%[email protected]> > For more options, visit this group at > http://groups.google.com/group/flex-mojos > > http://flexmojos.sonatype.org/ > -- You received this message because you are subscribed to the Google Groups "Flex Mojos" 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/flex-mojos http://flexmojos.sonatype.org/
