[ https://jira.codehaus.org/browse/SUREFIRE-815?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=287224#comment-287224 ]
Carson Gross commented on SUREFIRE-815: --------------------------------------- OK, sounds good. I can certainly hack something together quickly for you to look at. Basically what I need to do is extend the scanner to include ".gs" files that match the given conditions and, before we load the classes, call "Gosu.init()" and ensure that when we are loading classes we use the gosu classloader, which does the on-the-fly compilation of Gosu classes. Classloader issues indeed. ;) Thanks for your help. > Integrating Gosu (http://gosu-lang.org) tests into Surefire. > ------------------------------------------------------------ > > Key: SUREFIRE-815 > URL: https://jira.codehaus.org/browse/SUREFIRE-815 > Project: Maven Surefire > Issue Type: New Feature > Components: Maven Surefire Plugin > Affects Versions: 2.11 > Reporter: Carson Gross > > I would like to integrate Gosu-based tests into the Surefire plugin. Gosu is > a JVM-based programming language. It is compiled with a slightly different > model than java: rather than shipping class files, it ships source files and > compiles them on-demand, more like scripting languages such as JRuby. > We are developing a maven plugin that wires in gosu support for maven here: > > https://github.com/carsongross/maven-gosu-plugin/blob/master/src/main/java/org/gosu_lang/tools/maven/GosuArtifactMojo.java > As you can see, it adds POM dependencies to the core gosu jars, providing > gosu support. I'd like to extend this plugin to direct surefire how to > detect and run Gosu-based tests. > Investigating the surefire plugin code, it looks like what I need to do is > specify a custom DirectoryScanner. I have two questions on this (and I > apologize, I am very new to Maven, but could not find how to do this via the > documentation): > 1) Can I specify a custom scanner from the command line? That would get me > started writing my scanner. > 2) Is there an API in Maven for automatically setting properties (or does it > use the standard System properties API) such that I could pass this custom > DirectoryScanner along programmatically from our maven plugin? > In a private email, Kristian mentioned the following issue: > "There is one more hurdle you will need to solve, and that's how to add the > Gosu stuff to the classpath of the fork. I suppose you should add them as > dependencies to the surefire-plugin, but there is currently no automatic way > to transfer these to the fork." > I'm hoping that the fact that we add the dependencies to the parent POM > solves this problem (I assume that this is how other libraries are included > in surefire tests) but I do not understand the Maven dependencies and > classloader setup well enough to know for sure. I'll need to experiment. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira