From do-not-reply at jboss.org Sun Sep 4 20:37:40 2011
Content-Type: multipart/mixed; boundary="===============7299218851998051163=="
MIME-Version: 1.0
From: do-not-reply at jboss.org
To: hornetq-commits at lists.jboss.org
Subject: [hornetq-commits] JBoss hornetq SVN: r11294 - in
branches/STOMP11/tests/stomp-tests: v10/src/test/java/org and 10 other
directories.
Date: Sun, 04 Sep 2011 20:37:40 -0400
Message-ID: <201109050037.p850be3X032691@svn01.web.mwc.hst.phx2.redhat.com>
--===============7299218851998051163==
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: quoted-printable
Author: gaohoward
Date: 2011-09-04 20:37:40 -0400 (Sun, 04 Sep 2011)
New Revision: 11294
Added:
branches/STOMP11/tests/stomp-tests/v10/src/test/java/org/
branches/STOMP11/tests/stomp-tests/v10/src/test/java/org/hornetq/
branches/STOMP11/tests/stomp-tests/v10/src/test/java/org/hornetq/stomp/
branches/STOMP11/tests/stomp-tests/v10/src/test/java/org/hornetq/stomp/t=
ests/
branches/STOMP11/tests/stomp-tests/v10/src/test/java/org/hornetq/stomp/t=
ests/v10/
branches/STOMP11/tests/stomp-tests/v10/src/test/java/org/hornetq/stomp/t=
ests/v10/StompConnectionTest.java
branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/
branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/
branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/
branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/t=
ests/
branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/t=
ests/HornetQStompTestCase.java
branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/t=
ests/HornetQTestServer.java
branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/t=
ests/HornetQTestServerManager.java
branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/t=
ests/v11/
branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/t=
ests/v11/StompConnectionTest.java
Log:
test
Added: branches/STOMP11/tests/stomp-tests/v10/src/test/java/org/hornetq/sto=
mp/tests/v10/StompConnectionTest.java
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- branches/STOMP11/tests/stomp-tests/v10/src/test/java/org/hornetq/stomp/=
tests/v10/StompConnectionTest.java (rev 0)
+++ branches/STOMP11/tests/stomp-tests/v10/src/test/java/org/hornetq/stomp/=
tests/v10/StompConnectionTest.java 2011-09-05 00:37:40 UTC (rev 11294)
@@ -0,0 +1,6 @@
+package org.hornetq.stomp.tests.v10;
+
+public class StompConnectionTest
+{
+}
+
Added: branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/sto=
mp/tests/HornetQStompTestCase.java
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/=
tests/HornetQStompTestCase.java (rev 0)
+++ branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/=
tests/HornetQStompTestCase.java 2011-09-05 00:37:40 UTC (rev 11294)
@@ -0,0 +1,42 @@
+/*
+ * Copyright 2010 Red Hat, Inc.
+ * Red Hat licenses this file to you under the Apache License, version
+ * 2.0 (the "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ * implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+package org.hornetq.stomp.tests;
+
+import junit.framework.TestCase;
+
+/**
+ * =
+ * @author Howard Gao
+ *
+ */
+public class HornetQStompTestCase extends TestCase
+{
+ protected HornetQTestServerManager serverManager =3D new HornetQTestSer=
verManager();
+ protected int numberOfServers =3D 1;
+
+ protected void setUp()
+ {
+ for (int i =3D 0; i < numberOfServers; i++)
+ {
+ serverManager.createServer(i);
+ }
+ }
+ =
+ protected void tearDown()
+ {
+ for (int i =3D 0; i < numberOfServers; i++)
+ {
+ serverManager.shutdownServer(i);
+ }
+ }
+}
Added: branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/sto=
mp/tests/HornetQTestServer.java
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/=
tests/HornetQTestServer.java (rev 0)
+++ branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/=
tests/HornetQTestServer.java 2011-09-05 00:37:40 UTC (rev 11294)
@@ -0,0 +1,69 @@
+package org.hornetq.stomp.tests;
+
+import java.io.File;
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.List;
+
+public class HornetQTestServer
+{
+
+ public HornetQTestServer(int serverIndex)
+ {
+ =
+ }
+
+ public void start() throws IOException
+ {
+ String[] cmdArray =3D assembleCommandArray();
+ String[] envp =3D assembleEnvp();
+ File dir =3D getWorkingDir();
+ =
+ Process p =3D Runtime.getRuntime().exec(cmdArray, envp, dir);
+ }
+
+ private String[] assembleCommandArray()
+ {
+ //java
+ String javaHome =3D System.getProperty("java.home");
+ String javaPath =3D javaHome + File.separator + "bin" + File.separat=
or + "java";
+ =
+ List fullCommand =3D new ArrayList();
+ fullCommand.add("\"" + javaPath + "\"");
+ =
+ //classpath
+ fullCommand.add("-cp");
+ //hornetq jars
+ fullCommand.addAll(getHornetQServerRuntimeJars());
+ fullCommand.addAll(getTestClassBuildDirs());
+ =
+ =
+ return null;
+ }
+
+ private Collection extends String> getHornetQServerRuntimeJars()
+ {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ private String[] assembleEnvp()
+ {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ private File getWorkingDir()
+ {
+ // TODO Auto-generated method stub
+ return null;
+ }
+
+ public void shutdown()
+ {
+ // TODO Auto-generated method stub
+ =
+ }
+
+}
Added: branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/sto=
mp/tests/HornetQTestServerManager.java
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/=
tests/HornetQTestServerManager.java (rev 0)
+++ branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/=
tests/HornetQTestServerManager.java 2011-09-05 00:37:40 UTC (rev 11294)
@@ -0,0 +1,27 @@
+package org.hornetq.stomp.tests;
+
+import java.util.ArrayList;
+import java.util.LinkedHashMap;
+import java.util.List;
+import java.util.Map;
+
+public class HornetQTestServerManager
+{
+ =
+ List serverList =3D new ArrayList=
();
+ Map servers =3D new LinkedHashMap();
+
+ public void createServer(int serverId)
+ {
+ HornetQTestServer server =3D new HornetQTestServer(serverId);
+ server.start();
+ servers.put(serverId, server);
+ }
+
+ public void shutdownServer(int serverIndex)
+ {
+ HornetQTestServer server =3D servers.remove(serverIndex);
+ server.shutdown();
+ }
+
+}
Added: branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/sto=
mp/tests/v11/StompConnectionTest.java
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/=
tests/v11/StompConnectionTest.java (rev 0)
+++ branches/STOMP11/tests/stomp-tests/v11/src/test/java/org/hornetq/stomp/=
tests/v11/StompConnectionTest.java 2011-09-05 00:37:40 UTC (rev 11294)
@@ -0,0 +1,25 @@
+/*
+ * Copyright 2010 Red Hat, Inc.
+ * Red Hat licenses this file to you under the Apache License, version
+ * 2.0 (the "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ * implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+package org.hornetq.stomp.tests.v11;
+
+import org.hornetq.stomp.tests.HornetQStompTestCase;
+
+/**
+ * =
+ * @author Howard Gao
+ *
+ */
+public class StompConnectionTest extends HornetQStompTestCase
+{
+}
+
--===============7299218851998051163==--