You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by nd...@apache.org on 2006/08/26 23:07:16 UTC

svn commit: r437229 - /incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/

Author: ndbeyer
Date: Sat Aug 26 14:07:15 2006
New Revision: 437229

URL: http://svn.apache.org/viewvc?rev=437229&view=rev
Log:
Clean 'java.rmi' source and introduce additional test cases.

Added:
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/AccessExceptionTest.java   (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/AlreadyBoundExceptionTest.java   (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ConnectExceptionTest.java   (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ConnectIOExceptionTest.java   (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/MarshalExceptionTest.java   (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/NoSuchObjectExceptionTest.java   (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/NotBoundExceptionTest.java   (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/RMISecurityExceptionTest.java   (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerErrorTest.java   (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerExceptionTest.java   (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerRuntimeExceptionTest.java   (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/StubNotFoundExceptionTest.java   (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnexpectedExceptionTest.java   (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnknownHostExceptionTest.java   (with props)
    incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnmarshalExceptionTest.java   (with props)

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/AccessExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/AccessExceptionTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/AccessExceptionTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/AccessExceptionTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,50 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.AccessException;
+
+import junit.framework.TestCase;
+
+public class AccessExceptionTest extends TestCase {
+
+    /**
+     * {@link java.rmi.AccessException#AccessException(java.lang.String, java.lang.Exception)}.
+     */
+    public void testAccessExceptionStringException() {
+        AccessException e = new AccessException("fixture", null);
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+        assertNull(e.detail);
+        
+        NullPointerException npe = new NullPointerException();
+        e = new AccessException("fixture", npe);
+        assertTrue(e.getMessage().indexOf("fixture") > -1);
+        assertSame(npe, e.getCause());
+        assertSame(npe, e.detail);
+    }
+
+    /**
+     * {@link java.rmi.AccessException#AccessException(java.lang.String)}.
+     */
+    public void testAccessExceptionString() {
+        AccessException e = new AccessException("fixture");
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+        assertNull(e.detail);
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/AccessExceptionTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/AlreadyBoundExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/AlreadyBoundExceptionTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/AlreadyBoundExceptionTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/AlreadyBoundExceptionTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,42 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.AlreadyBoundException;
+
+import junit.framework.TestCase;
+
+public class AlreadyBoundExceptionTest extends TestCase {
+
+    /**
+     * {@link java.rmi.AlreadyBoundException#AlreadyBoundException(java.lang.String)}.
+     */
+    public void testAlreadyBoundExceptionString() {
+        AlreadyBoundException e = new AlreadyBoundException("fixture");
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+    }
+
+    /**
+     * {@link java.rmi.AlreadyBoundException#AlreadyBoundException()}.
+     */
+    public void testAlreadyBoundException() {
+        AlreadyBoundException e = new AlreadyBoundException();
+        assertNull(e.getMessage());
+        assertNull(e.getCause());
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/AlreadyBoundExceptionTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ConnectExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ConnectExceptionTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ConnectExceptionTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ConnectExceptionTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,45 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.ConnectException;
+
+import junit.framework.TestCase;
+
+public class ConnectExceptionTest extends TestCase {
+
+    /**
+     * {@link java.rmi.ConnectException#ConnectException(java.lang.String, java.lang.Exception)}.
+     */
+    public void testConnectExceptionStringException() {
+        NullPointerException npe = new NullPointerException();
+        ConnectException e = new ConnectException("fixture", npe);
+        assertTrue(e.getMessage().indexOf("fixture") > -1);
+        assertSame(npe, e.getCause());
+        assertSame(npe, e.detail);
+    }
+
+    /**
+     * {@link java.rmi.ConnectException#ConnectException(java.lang.String)}.
+     */
+    public void testConnectExceptionString() {
+        ConnectException e = new ConnectException("fixture");
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+        assertNull(e.detail);
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ConnectExceptionTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ConnectIOExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ConnectIOExceptionTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ConnectIOExceptionTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ConnectIOExceptionTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,45 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.ConnectIOException;
+
+import junit.framework.TestCase;
+
+public class ConnectIOExceptionTest extends TestCase {
+
+    /**
+     * {@link java.rmi.ConnectIOException#ConnectIOException(java.lang.String, java.lang.Exception)}.
+     */
+    public void testConnectIOExceptionStringException() {
+        NullPointerException npe = new NullPointerException();
+        ConnectIOException e = new ConnectIOException("fixture", npe);
+        assertTrue(e.getMessage().indexOf("fixture") > -1);
+        assertSame(npe, e.getCause());
+        assertSame(npe, e.detail);
+    }
+
+    /**
+     * {@link java.rmi.ConnectIOException#ConnectIOException(java.lang.String)}.
+     */
+    public void testConnectIOExceptionString() {
+        ConnectIOException e = new ConnectIOException("fixture");
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+        assertNull(e.detail);
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ConnectIOExceptionTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/MarshalExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/MarshalExceptionTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/MarshalExceptionTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/MarshalExceptionTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,45 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.MarshalException;
+
+import junit.framework.TestCase;
+
+public class MarshalExceptionTest extends TestCase {
+
+    /**
+     * {@link java.rmi.MarshalException#MarshalException(java.lang.String, java.lang.Exception)}.
+     */
+    public void testMarshalExceptionStringException() {
+        NullPointerException npe = new NullPointerException();
+        MarshalException e = new MarshalException("fixture", npe);
+        assertTrue(e.getMessage().indexOf("fixture") > -1);
+        assertSame(npe, e.getCause());
+        assertSame(npe, e.detail);
+    }
+
+    /**
+     * {@link java.rmi.MarshalException#MarshalException(java.lang.String)}.
+     */
+    public void testMarshalExceptionString() {
+        MarshalException e = new MarshalException("fixture");
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+        assertNull(e.detail);
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/MarshalExceptionTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/NoSuchObjectExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/NoSuchObjectExceptionTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/NoSuchObjectExceptionTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/NoSuchObjectExceptionTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,34 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.NoSuchObjectException;
+
+import junit.framework.TestCase;
+
+public class NoSuchObjectExceptionTest extends TestCase {
+
+    /**
+     * {@link java.rmi.NoSuchObjectException#NoSuchObjectException(java.lang.String)}.
+     */
+    public void testNoSuchObjectException() {
+        NoSuchObjectException e = new NoSuchObjectException("fixture");
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+        assertNull(e.detail);
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/NoSuchObjectExceptionTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/NotBoundExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/NotBoundExceptionTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/NotBoundExceptionTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/NotBoundExceptionTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,42 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.NotBoundException;
+
+import junit.framework.TestCase;
+
+public class NotBoundExceptionTest extends TestCase {
+
+    /**
+     * {@link java.rmi.NotBoundException#NotBoundException(java.lang.String)}.
+     */
+    public void testNotBoundExceptionString() {
+        NotBoundException e = new NotBoundException("fixture");
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+    }
+
+    /**
+     * {@link java.rmi.NotBoundException#NotBoundException()}.
+     */
+    public void testNotBoundException() {
+        NotBoundException e = new NotBoundException();
+        assertNull(e.getCause());
+        assertNull(e.getMessage());
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/NotBoundExceptionTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/RMISecurityExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/RMISecurityExceptionTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/RMISecurityExceptionTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/RMISecurityExceptionTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,43 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.RMISecurityException;
+
+import junit.framework.TestCase;
+
+@SuppressWarnings("deprecation")
+public class RMISecurityExceptionTest extends TestCase {
+
+    /**
+     * {@link java.rmi.RMISecurityException#RMISecurityException(java.lang.String, java.lang.String)}.
+     */
+    public void testRMISecurityExceptionStringString() {
+        RMISecurityException e = new RMISecurityException("fixture", "ignored");
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+    }
+
+    /**
+     * {@link java.rmi.RMISecurityException#RMISecurityException(java.lang.String)}.
+     */
+    public void testRMISecurityExceptionString() {
+        RMISecurityException e = new RMISecurityException("fixture");
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/RMISecurityExceptionTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerErrorTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerErrorTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerErrorTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerErrorTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,35 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.ServerError;
+
+import junit.framework.TestCase;
+
+public class ServerErrorTest extends TestCase {
+
+    /**
+     * {@link java.rmi.ServerError#ServerError(java.lang.String, java.lang.Error)}.
+     */
+    public void testServerError() {
+        Error t = new Error();
+        ServerError e = new ServerError("fixture", t);
+        assertTrue(e.getMessage().indexOf("fixture") > -1);
+        assertSame(t, e.getCause());
+        assertSame(t, e.detail);
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerErrorTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerExceptionTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerExceptionTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerExceptionTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,45 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.ServerException;
+
+import junit.framework.TestCase;
+
+public class ServerExceptionTest extends TestCase {
+
+    /**
+     * {@link java.rmi.ServerException#ServerException(java.lang.String, java.lang.Exception)}.
+     */
+    public void testServerExceptionStringException() {
+        NullPointerException npe = new NullPointerException();
+        ServerException e = new ServerException("fixture", npe);
+        assertTrue(e.getMessage().indexOf("fixture") > -1);
+        assertSame(npe, e.getCause());
+        assertSame(npe, e.detail);
+    }
+
+    /**
+     * {@link java.rmi.ServerException#ServerException(java.lang.String)}.
+     */
+    public void testServerExceptionString() {
+        ServerException e = new ServerException("fixture");
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+        assertNull(e.detail);
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerExceptionTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerRuntimeExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerRuntimeExceptionTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerRuntimeExceptionTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerRuntimeExceptionTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,36 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.ServerRuntimeException;
+
+import junit.framework.TestCase;
+
+@SuppressWarnings("deprecation")
+public class ServerRuntimeExceptionTest extends TestCase {
+
+    /**
+     * {@link java.rmi.ServerRuntimeException#ServerRuntimeException(java.lang.String, java.lang.Exception)}.
+     */
+    public void testServerRuntimeExceptionStringException() {
+        NullPointerException npe = new NullPointerException();
+        ServerRuntimeException e = new ServerRuntimeException("fixture", npe);
+        assertTrue(e.getMessage().indexOf("fixture") > -1);
+        assertSame(npe, e.getCause());
+        assertSame(npe, e.detail);
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/ServerRuntimeExceptionTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/StubNotFoundExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/StubNotFoundExceptionTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/StubNotFoundExceptionTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/StubNotFoundExceptionTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,45 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.StubNotFoundException;
+
+import junit.framework.TestCase;
+
+public class StubNotFoundExceptionTest extends TestCase {
+
+    /**
+     * {@link java.rmi.StubNotFoundException#StubNotFoundException(java.lang.String, java.lang.Exception)}.
+     */
+    public void testStubNotFoundExceptionStringException() {
+        NullPointerException npe = new NullPointerException();
+        StubNotFoundException e = new StubNotFoundException("fixture", npe);
+        assertTrue(e.getMessage().indexOf("fixture") > -1);
+        assertSame(npe, e.getCause());
+        assertSame(npe, e.detail);
+    }
+
+    /**
+     * {@link java.rmi.StubNotFoundException#StubNotFoundException(java.lang.String)}.
+     */
+    public void testStubNotFoundExceptionString() {
+        StubNotFoundException e = new StubNotFoundException("fixture");
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+        assertNull(e.detail);
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/StubNotFoundExceptionTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnexpectedExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnexpectedExceptionTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnexpectedExceptionTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnexpectedExceptionTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,45 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.UnexpectedException;
+
+import junit.framework.TestCase;
+
+public class UnexpectedExceptionTest extends TestCase {
+
+    /**
+     * {@link java.rmi.UnexpectedException#UnexpectedException(java.lang.String, java.lang.Exception)}.
+     */
+    public void testUnexpectedExceptionStringException() {
+        NullPointerException npe = new NullPointerException();
+        UnexpectedException e = new UnexpectedException("fixture", npe);
+        assertTrue(e.getMessage().indexOf("fixture") > -1);
+        assertSame(npe, e.getCause());
+        assertSame(npe, e.detail);
+    }
+
+    /**
+     * {@link java.rmi.UnexpectedException#UnexpectedException(java.lang.String)}.
+     */
+    public void testUnexpectedExceptionString() {
+        UnexpectedException e = new UnexpectedException("fixture");
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+        assertNull(e.detail);
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnexpectedExceptionTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnknownHostExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnknownHostExceptionTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnknownHostExceptionTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnknownHostExceptionTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,45 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.UnknownHostException;
+
+import junit.framework.TestCase;
+
+public class UnknownHostExceptionTest extends TestCase {
+
+    /**
+     * {@link java.rmi.UnknownHostException#UnknownHostException(java.lang.String, java.lang.Exception)}.
+     */
+    public void testUnknownHostExceptionStringException() {
+        NullPointerException npe = new NullPointerException();
+        UnknownHostException e = new UnknownHostException("fixture", npe);
+        assertTrue(e.getMessage().indexOf("fixture") > -1);
+        assertSame(npe, e.getCause());
+        assertSame(npe, e.detail);
+    }
+
+    /**
+     * {@link java.rmi.UnknownHostException#UnknownHostException(java.lang.String)}.
+     */
+    public void testUnknownHostExceptionString() {
+        UnknownHostException e = new UnknownHostException("fixture");
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+        assertNull(e.detail);
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnknownHostExceptionTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnmarshalExceptionTest.java
URL: http://svn.apache.org/viewvc/incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnmarshalExceptionTest.java?rev=437229&view=auto
==============================================================================
--- incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnmarshalExceptionTest.java (added)
+++ incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnmarshalExceptionTest.java Sat Aug 26 14:07:15 2006
@@ -0,0 +1,45 @@
+/* Copyright 2006 The Apache Software Foundation or its licensors, as applicable
+ * 
+ * Licensed 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.apache.harmony.rmi;
+
+import java.rmi.UnmarshalException;
+
+import junit.framework.TestCase;
+
+public class UnmarshalExceptionTest extends TestCase {
+
+    /**
+     * {@link java.rmi.UnmarshalException#UnmarshalException(java.lang.String, java.lang.Exception)}.
+     */
+    public void testUnmarshalExceptionStringException() {
+        NullPointerException npe = new NullPointerException();
+        UnmarshalException e = new UnmarshalException("fixture", npe);
+        assertTrue(e.getMessage().indexOf("fixture") > -1);
+        assertSame(npe, e.getCause());
+        assertSame(npe, e.detail);
+    }
+
+    /**
+     * {@link java.rmi.UnmarshalException#UnmarshalException(java.lang.String)}.
+     */
+    public void testUnmarshalExceptionString() {
+        UnmarshalException e = new UnmarshalException("fixture");
+        assertEquals("fixture", e.getMessage());
+        assertNull(e.getCause());
+        assertNull(e.detail);
+    }
+
+}

Propchange: incubator/harmony/enhanced/classlib/trunk/modules/rmi/src/test/api/java/org/apache/harmony/rmi/UnmarshalExceptionTest.java
------------------------------------------------------------------------------
    svn:eol-style = native