[jboss-cvs] JBossAS SVN: r64364 - in projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config: test and 1 other directory.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Tue Jul 31 06:17:24 EDT 2007
Author: alesj
Date: 2007-07-31 06:17:24 -0400 (Tue, 31 Jul 2007)
New Revision: 64364
Added:
projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/FromStringSimpleBean.java
projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigureFromStringAnnotationTestCase.java
Removed:
projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/FromObjectSimpleBean.java
projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigureFromObjectAnnotationTestCase.java
projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigureFromObjectXMLTestCase.java
Modified:
projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigTestSuite.java
Log:
Removed XML and @annotation FromObject tests - no such equivalent.
Changed the @annotation one to FromString.
Deleted: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/FromObjectSimpleBean.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/FromObjectSimpleBean.java 2007-07-31 10:11:26 UTC (rev 64363)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/FromObjectSimpleBean.java 2007-07-31 10:17:24 UTC (rev 64364)
@@ -1,181 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.kernel.config.support;
-
-import java.math.BigDecimal;
-import java.math.BigInteger;
-import java.util.Date;
-
-import org.jboss.beans.metadata.plugins.annotations.StringValue;
-
-/**
- * A simple bean
- *
- * @author <a href="ales.justin at jboss.com">Ales Justin</a>
- */
-public class FromObjectSimpleBean extends SimpleBean
-{
- public FromObjectSimpleBean()
- {
- super();
- }
-
- // Public --------------------------------------------------------
-
- @StringValue("Z")
- public void setEnumProperty(Alphabet enumProperty)
- {
- super.setEnumProperty(enumProperty);
- }
-
- @StringValue("StringValue")
- public void setOverloadedProperty(String overloadedProperty)
- {
- super.setOverloadedProperty(overloadedProperty);
- }
-
- @StringValue("StringValue")
- public void setAString(String string)
- {
- super.setAString(string);
- }
-
- @StringValue("123")
- public void setAShort(Short short1)
- {
- super.setAShort(short1);
- }
-
- @StringValue("123")
- public void setAshort(short ashort)
- {
- super.setAshort(ashort);
- }
-
- @StringValue("1234")
- public void setAnInt(Integer anInt)
- {
- super.setAnInt(anInt);
- }
-
- @StringValue("1234")
- public void setAnint(int anint)
- {
- super.setAnint(anint);
- }
-
- @StringValue("12345")
- public void setALong(Long long1)
- {
- super.setALong(long1);
- }
-
- @StringValue("12345")
- public void setAlong(long along)
- {
- super.setAlong(along);
- }
-
- @StringValue("3.14")
- public void setAFloat(Float float1)
- {
- super.setAFloat(float1);
- }
-
- @StringValue("3.14")
- public void setAfloat(float afloat)
- {
- super.setAfloat(afloat);
- }
-
- @StringValue("3.14e12")
- public void setADouble(Double double1)
- {
- super.setADouble(double1);
- }
-
- @StringValue("3.14e12")
- public void setAdouble(double adouble)
- {
- super.setAdouble(adouble);
- }
-
- @StringValue("Mon Jan 01 00:00:00 CET 2001")
- public void setADate(Date date)
- {
- super.setADate(date);
- }
-
- @StringValue("a")
- public void setACharacter(Character character)
- {
- super.setACharacter(character);
- }
-
- @StringValue("a")
- public void setAchar(char achar)
- {
- super.setAchar(achar);
- }
-
- @StringValue("12")
- public void setAByte(Byte byte1)
- {
- super.setAByte(byte1);
- }
-
- @StringValue("12")
- public void setAbyte(byte abyte)
- {
- super.setAbyte(abyte);
- }
-
- @StringValue(value="12345", type="java.lang.Long")
- public void setANumber(Number number)
- {
- super.setANumber(number);
- }
-
- @StringValue("true")
- public void setABoolean(Boolean boolean1)
- {
- super.setABoolean(boolean1);
- }
-
- @StringValue("true")
- public void setAboolean(boolean aboolean)
- {
- super.setAboolean(aboolean);
- }
-
- @StringValue("123456")
- public void setABigInteger(BigInteger bigInteger)
- {
- super.setABigInteger(bigInteger);
- }
-
- @StringValue("12e4")
- public void setABigDecimal(BigDecimal bigDecimal)
- {
- super.setABigDecimal(bigDecimal);
- }
-}
Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/FromStringSimpleBean.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/FromStringSimpleBean.java (rev 0)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/FromStringSimpleBean.java 2007-07-31 10:17:24 UTC (rev 64364)
@@ -0,0 +1,181 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* This is free software; you can redistribute it and/or modify it
+* under the terms of the GNU Lesser General Public License as
+* published by the Free Software Foundation; either version 2.1 of
+* the License, or (at your option) any later version.
+*
+* This software is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+* Lesser General Public License for more details.
+*
+* You should have received a copy of the GNU Lesser General Public
+* License along with this software; if not, write to the Free
+* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+*/
+package org.jboss.test.kernel.config.support;
+
+import java.util.Date;
+import java.math.BigInteger;
+import java.math.BigDecimal;
+
+import org.jboss.beans.metadata.plugins.annotations.StringValue;
+
+/**
+ * A simple bean
+ *
+ * @author <a href="ales.justin at jboss.com">Ales Justin</a>
+ */
+public class FromStringSimpleBean extends SimpleBean
+{
+ public FromStringSimpleBean()
+ {
+ super();
+ }
+
+ // Public --------------------------------------------------------
+
+ @StringValue("Z")
+ public void setEnumProperty(Alphabet enumProperty)
+ {
+ super.setEnumProperty(enumProperty);
+ }
+
+ @StringValue("StringValue")
+ public void setOverloadedProperty(String overloadedProperty)
+ {
+ super.setOverloadedProperty(overloadedProperty);
+ }
+
+ @StringValue("StringValue")
+ public void setAString(String string)
+ {
+ super.setAString(string);
+ }
+
+ @StringValue("123")
+ public void setAShort(Short short1)
+ {
+ super.setAShort(short1);
+ }
+
+ @StringValue("123")
+ public void setAshort(short ashort)
+ {
+ super.setAshort(ashort);
+ }
+
+ @StringValue("1234")
+ public void setAnInt(Integer anInt)
+ {
+ super.setAnInt(anInt);
+ }
+
+ @StringValue("1234")
+ public void setAnint(int anint)
+ {
+ super.setAnint(anint);
+ }
+
+ @StringValue("12345")
+ public void setALong(Long long1)
+ {
+ super.setALong(long1);
+ }
+
+ @StringValue("12345")
+ public void setAlong(long along)
+ {
+ super.setAlong(along);
+ }
+
+ @StringValue("3.14")
+ public void setAFloat(Float float1)
+ {
+ super.setAFloat(float1);
+ }
+
+ @StringValue("3.14")
+ public void setAfloat(float afloat)
+ {
+ super.setAfloat(afloat);
+ }
+
+ @StringValue("3.14e12")
+ public void setADouble(Double double1)
+ {
+ super.setADouble(double1);
+ }
+
+ @StringValue("3.14e12")
+ public void setAdouble(double adouble)
+ {
+ super.setAdouble(adouble);
+ }
+
+ @StringValue("Mon Jan 01 00:00:00 CET 2001")
+ public void setADate(Date date)
+ {
+ super.setADate(date);
+ }
+
+ @StringValue("a")
+ public void setACharacter(Character character)
+ {
+ super.setACharacter(character);
+ }
+
+ @StringValue("a")
+ public void setAchar(char achar)
+ {
+ super.setAchar(achar);
+ }
+
+ @StringValue("12")
+ public void setAByte(Byte byte1)
+ {
+ super.setAByte(byte1);
+ }
+
+ @StringValue("12")
+ public void setAbyte(byte abyte)
+ {
+ super.setAbyte(abyte);
+ }
+
+ @StringValue(value="12345", type="java.lang.Long")
+ public void setANumber(Number number)
+ {
+ super.setANumber(number);
+ }
+
+ @StringValue("true")
+ public void setABoolean(Boolean boolean1)
+ {
+ super.setABoolean(boolean1);
+ }
+
+ @StringValue("true")
+ public void setAboolean(boolean aboolean)
+ {
+ super.setAboolean(aboolean);
+ }
+
+ @StringValue("123456")
+ public void setABigInteger(BigInteger bigInteger)
+ {
+ super.setABigInteger(bigInteger);
+ }
+
+ @StringValue("12e4")
+ public void setABigDecimal(BigDecimal bigDecimal)
+ {
+ super.setABigDecimal(bigDecimal);
+ }
+}
Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigTestSuite.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigTestSuite.java 2007-07-31 10:11:26 UTC (rev 64363)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigTestSuite.java 2007-07-31 10:17:24 UTC (rev 64364)
@@ -51,10 +51,9 @@
suite.addTest(ConfigureAttributeFromObjectTestCase.suite());
suite.addTest(ConfigureAttributeFromStringTestCase.suite());
suite.addTest(ConfigureFromObjectTestCase.suite());
- suite.addTest(ConfigureFromObjectXMLTestCase.suite());
- suite.addTest(ConfigureFromObjectAnnotationTestCase.suite());
suite.addTest(ConfigureFromStringTestCase.suite());
suite.addTest(ConfigureFromStringXMLTestCase.suite());
+ suite.addTest(ConfigureFromStringAnnotationTestCase.suite());
suite.addTest(CollectionTestCase.suite());
suite.addTest(CollectionXMLTestCase.suite());
suite.addTest(SetTestCase.suite());
Deleted: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigureFromObjectAnnotationTestCase.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigureFromObjectAnnotationTestCase.java 2007-07-31 10:11:26 UTC (rev 64363)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigureFromObjectAnnotationTestCase.java 2007-07-31 10:17:24 UTC (rev 64364)
@@ -1,71 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.kernel.config.test;
-
-import java.math.BigDecimal;
-import java.math.BigInteger;
-import java.util.Date;
-
-import junit.framework.Test;
-import org.jboss.beans.metadata.plugins.builder.BeanMetaDataBuilderFactory;
-import org.jboss.beans.metadata.spi.builder.BeanMetaDataBuilder;
-import org.jboss.test.kernel.config.support.FromObjectSimpleBean;
-import org.jboss.test.kernel.config.support.SimpleBean;
-
-/**
- * Configuration from object Test Case.
- *
- * @author <a href="ales.justin at jboss.com">Ales Justin</a>
- */
-public class ConfigureFromObjectAnnotationTestCase extends ConfigureFromObjectTestCase
-{
- public static Test suite()
- {
- return suite(ConfigureFromObjectAnnotationTestCase.class);
- }
-
- public ConfigureFromObjectAnnotationTestCase(String name)
- {
- super(name);
- }
-
- protected SimpleBean createSimpleBean(
- String stringValue,
- Byte byteValue,
- Boolean booleanValue,
- Character characterValue,
- Short shortValue,
- Integer integerValue,
- Long longValue,
- Float floatValue,
- Double doubleValue,
- Date dateValue,
- BigDecimal bigDecimalValue,
- BigInteger bigIntegerValue,
- SimpleBean.Alphabet enumValue
- )
- throws Throwable
- {
- BeanMetaDataBuilder builder = BeanMetaDataBuilderFactory.createBuilder("SimpleBean", FromObjectSimpleBean.class.getName());
- return (SimpleBean)instantiate(builder.getBeanMetaData());
- }
-}
Deleted: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigureFromObjectXMLTestCase.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigureFromObjectXMLTestCase.java 2007-07-31 10:11:26 UTC (rev 64363)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigureFromObjectXMLTestCase.java 2007-07-31 10:17:24 UTC (rev 64364)
@@ -1,70 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* This is free software; you can redistribute it and/or modify it
-* under the terms of the GNU Lesser General Public License as
-* published by the Free Software Foundation; either version 2.1 of
-* the License, or (at your option) any later version.
-*
-* This software is distributed in the hope that it will be useful,
-* but WITHOUT ANY WARRANTY; without even the implied warranty of
-* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-* Lesser General Public License for more details.
-*
-* You should have received a copy of the GNU Lesser General Public
-* License along with this software; if not, write to the Free
-* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
-* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-*/
-package org.jboss.test.kernel.config.test;
-
-import java.util.Date;
-import java.math.BigDecimal;
-import java.math.BigInteger;
-
-import junit.framework.Test;
-import org.jboss.test.kernel.config.support.SimpleBean;
-import org.jboss.test.kernel.config.support.XMLUtil;
-
-/**
- * Configuration from object Test Case.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision$
- */
-public class ConfigureFromObjectXMLTestCase extends ConfigureFromObjectTestCase
-{
- public static Test suite()
- {
- return suite(ConfigureFromObjectXMLTestCase.class);
- }
-
- public ConfigureFromObjectXMLTestCase(String name)
- {
- super(name, true);
- }
-
- protected SimpleBean createSimpleBean(
- String stringValue,
- Byte byteValue,
- Boolean booleanValue,
- Character characterValue,
- Short shortValue,
- Integer integerValue,
- Long longValue,
- Float floatValue,
- Double doubleValue,
- Date dateValue,
- BigDecimal bigDecimalValue,
- BigInteger bigIntegerValue,
- SimpleBean.Alphabet enumValue
- )
- throws Throwable
- {
- XMLUtil util = bootstrapXML(true);
- return (SimpleBean) util.getBean("SimpleBean");
- }
-}
\ No newline at end of file
Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigureFromStringAnnotationTestCase.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigureFromStringAnnotationTestCase.java (rev 0)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigureFromStringAnnotationTestCase.java 2007-07-31 10:17:24 UTC (rev 64364)
@@ -0,0 +1,53 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* This is free software; you can redistribute it and/or modify it
+* under the terms of the GNU Lesser General Public License as
+* published by the Free Software Foundation; either version 2.1 of
+* the License, or (at your option) any later version.
+*
+* This software is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+* Lesser General Public License for more details.
+*
+* You should have received a copy of the GNU Lesser General Public
+* License along with this software; if not, write to the Free
+* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+*/
+package org.jboss.test.kernel.config.test;
+
+import junit.framework.Test;
+import org.jboss.beans.metadata.plugins.builder.BeanMetaDataBuilderFactory;
+import org.jboss.beans.metadata.spi.builder.BeanMetaDataBuilder;
+import org.jboss.test.kernel.config.support.FromStringSimpleBean;
+import org.jboss.test.kernel.config.support.SimpleBean;
+
+/**
+ * Configuration from object Test Case.
+ *
+ * @author <a href="ales.justin at jboss.com">Ales Justin</a>
+ */
+public class ConfigureFromStringAnnotationTestCase extends ConfigureFromStringTestCase
+{
+ public static Test suite()
+ {
+ return suite(ConfigureFromStringAnnotationTestCase.class);
+ }
+
+ public ConfigureFromStringAnnotationTestCase(String name)
+ {
+ super(name);
+ }
+
+
+ protected SimpleBean configure() throws Throwable
+ {
+ BeanMetaDataBuilder builder = BeanMetaDataBuilderFactory.createBuilder("SimpleBean", FromStringSimpleBean.class.getName());
+ return (SimpleBean)instantiate(builder.getBeanMetaData());
+ }
+}
More information about the jboss-cvs-commits
mailing list