Permalink
Browse files

IN PROGRESS - issue NEXUS-2297: Improve selenium tests speed

https://issues.sonatype.org/browse/NEXUS-2297

git-svn-id: file:///opt/svn/repositories/sonatype.org/plugins/trunk/selenium-maven-plugin@342 c2a14038-686d-4adc-8740-a14e5738cb64
  • Loading branch information...
1 parent 03a7698 commit 46dad8d842bc5073e7bdb3f6f4f0745d2139e518 @velo velo committed Oct 13, 2009
Showing with 35 additions and 36 deletions.
  1. +35 −36 src/main/groovy/org/sonatype/maven/plugin/selenium/StopServerMojo.groovy
View
71 src/main/groovy/org/sonatype/maven/plugin/selenium/StopServerMojo.groovy
@@ -31,40 +31,39 @@ import org.codehaus.groovy.maven.mojo.GroovyMojo
* @author <a href="mailto:jason@planet57.com">Jason Dillon</a>
*/
class StopServerMojo
- extends GroovyMojo
-{
- /**
- * The port number of the server to connect to.
- *
- * @parameter expression="${port}" default-value="4444"
- */
- int port
-
- /**
- * Skip goal execution
- *
- * @parameter expression="${maven.test.skip}" default-value="false"
- */
- boolean skip
-
- //
- // Mojo
- //
-
- void execute() {
- if (skip) {
- log.info('Skipping execution')
- return
- }
-
- println('Stopping Selenium server...')
-
- def url = new URL("http://localhost:$port/selenium-server/driver/?cmd=shutDown")
-
- log.debug("Stop request URL: $url")
-
- url.openConnection().content
-
- println('Stop request sent')
- }
+extends GroovyMojo {
+ /**
+ * The port number of the server to connect to.
+ *
+ * @parameter expression="${port}" default-value="4444"
+ */
+ int port
+
+ /**
+ * Skip goal execution
+ *
+ * @parameter expression="${maven.test.skip}" default-value="false"
+ */
+ boolean skip
+
+ //
+ // Mojo
+ //
+
+ void execute() {
+ if (skip) {
+ log.info('Skipping execution')
+ return
+ }
+
+ println('Stopping Selenium server...')
+
+ def url = new URL("http://localhost:$port/selenium-server/driver/?cmd=shutDownSeleniumServer")
+
+ log.debug("Stop request URL: $url")
+
+ url.openConnection().content
+
+ println('Stop request sent')
+ }
}

0 comments on commit 46dad8d

Please sign in to comment.