openamf/src/java/org/openamf/util OpenAMFUtilsTest.java,1.4,1.5

Sean Sullivan <[email protected]> Mon, 21 Jun 2004 06:07:03 +0000
Newsgroups gmane.comp.java.openamf.cvs
Message-ID <[email protected]>
Update of /cvsroot/openamf/openamf/src/java/org/openamf/util
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv26333/src/java/org/openamf/util

Modified Files:
	OpenAMFUtilsTest.java 
Log Message:


Index: OpenAMFUtilsTest.java
===================================================================
RCS file: /cvsroot/openamf/openamf/src/java/org/openamf/util/OpenAMFUtilsTest.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** OpenAMFUtilsTest.java	21 Jun 2004 05:30:42 -0000	1.4
--- OpenAMFUtilsTest.java	21 Jun 2004 06:07:00 -0000	1.5
***************
*** 69,72 ****
--- 69,83 ----
    }
  
+   public void testDecodeNumberParameter() throws Exception
+   {
+   	Number n = new Integer(1053);
+   	
+ 	Object decodedParam = OpenAMFUtils.decodeParameter(
+ 								n, n.getClass());
+ 	
+ 	assertTrue(decodedParam instanceof Number);
+   }
+ 
+ 
    public void testDecodeBigDecimalParameter() throws Exception
    {
***************
*** 88,91 ****
--- 99,113 ----
    	assertTrue(decodedParam instanceof Integer);
    }
+   
+   public void testDecodeShortParameter() throws Exception
+   {
+   	Short s = new Short( (short) 2);
+   	
+   	Object decodedParam = OpenAMFUtils.decodeParameter(
+   			s, Short.TYPE);
+   	
+   	assertTrue(decodedParam instanceof Short);
+   }
+ 
  
    public void testDecodeLongParameter() throws Exception



-------------------------------------------------------
This SF.Net email is sponsored by The 2004 JavaOne(SM) Conference
Learn from the experts at JavaOne(SM), Sun's Worldwide Java Developer
Conference, June 28 - July 1 at the Moscone Center in San Francisco, CA
REGISTER AND SAVE! http://java.sun.com/javaone/sf Priority Code NWMGYKND