diff options
Diffstat (limited to 'tests')
51 files changed, 733 insertions, 0 deletions
diff --git a/tests/run-test-suite.py b/tests/run-test-suite.py new file mode 100644 index 0000000..6b123fc --- /dev/null +++ b/tests/run-test-suite.py @@ -0,0 +1,8 @@ +import unittest as u +import testsuite +import sys + +suite = u.defaultTestLoader.loadTestsFromNames(testsuite.__all__, testsuite) + +result = u.TextTestRunner().run(suite) +sys.exit(not result.wasSuccessful()) diff --git a/tests/run-test-suite2.py b/tests/run-test-suite2.py new file mode 100644 index 0000000..a386268 --- /dev/null +++ b/tests/run-test-suite2.py @@ -0,0 +1,8 @@ +import unittest as u +import testsuite2 +import sys + +suite = u.defaultTestLoader.loadTestsFromNames(testsuite2.__all__, testsuite2) + +result = u.TextTestRunner().run(suite) +sys.exit(not result.wasSuccessful()) diff --git a/tests/test-python3.sh b/tests/test-python3.sh new file mode 100755 index 0000000..6f5a89b --- /dev/null +++ b/tests/test-python3.sh @@ -0,0 +1,2 @@ +#!/bin/sh +PYTHONPATH="../src" python3 run-test-suite.py diff --git a/tests/test.sh b/tests/test.sh new file mode 100755 index 0000000..f2c1246 --- /dev/null +++ b/tests/test.sh @@ -0,0 +1,2 @@ +#!/bin/sh +PYTHONPATH="../src" python run-test-suite.py diff --git a/tests/test2.sh b/tests/test2.sh new file mode 100755 index 0000000..933e88a --- /dev/null +++ b/tests/test2.sh @@ -0,0 +1,2 @@ +#!/bin/sh +PYTHONPATH="../src" python run-test-suite2.py diff --git a/tests/testsuite/EnvironmentManager.py b/tests/testsuite/EnvironmentManager.py new file mode 100644 index 0000000..fe810e8 --- /dev/null +++ b/tests/testsuite/EnvironmentManager.py @@ -0,0 +1,23 @@ +import unittest +import os + +from java_config_2.EnvironmentManager import EnvironmentManager as em + +class TestEnvironmentManager(unittest.TestCase): + path="" + + def test_load_packages(self): + em.packages = {} + em.load_packages() + self.assertEqual(len(em.packages), 11) + + def test_get_package(self): + em.get_package('ant-cores') + + def test_build_dep_path(self): + self.assertTrue( len(em.build_dep_path(["jdbc"], "CLASSPATH", set())) > 2) + +if __name__ == '__main__': + unittest.main() + +# vim:set expandtab tabstop=4 shiftwidth=4 softtabstop=4 nowrap: diff --git a/tests/testsuite/Package.py b/tests/testsuite/Package.py new file mode 100644 index 0000000..52c2405 --- /dev/null +++ b/tests/testsuite/Package.py @@ -0,0 +1,29 @@ +import unittest +import os + +from java_config_2.Package import Package + +class TestPackage(unittest.TestCase): + path = os.path.join(os.path.dirname(__file__), 'packages', '%s/package.env') + + def load_package(self, package): + config = TestPackage.path % package + return Package(package, config) + + def setUp(self): + self.ant = self.load_package('ant-cores') + + def test_package_info(self): + #using a package we definitely + #know will not be into the tree + #to ensure we ain't using real system packages. + self.assertEqual(self.ant.name(), 'ant-cores') + self.assertEqual(self.ant.description(), "Description: %s" % self.ant.name()) + self.assertEqual(self.ant.target(), "1.4") + self.assertTrue(self.ant.query('JAVADOC_PATH')) + self.assertFalse(self.ant.query('VAR_SHOULD_NOT_EXIST')) + +if __name__ == '__main__': + unittest.main() + +# vim:set expandtab tabstop=4 shiftwidth=4 softtabstop=4 nowrap: diff --git a/tests/testsuite/VM.py b/tests/testsuite/VM.py new file mode 100644 index 0000000..a8ecff0 --- /dev/null +++ b/tests/testsuite/VM.py @@ -0,0 +1,29 @@ +import unittest +from java_config_2.VM import VM +import os + +class TestVM(unittest.TestCase): + path = os.path.join(os.path.dirname(__file__), 'vm_configs') + + def load_vm(self, vm): + config = os.path.join(self.path,vm) + return VM(config) + + def setUp(self): + self.ibm = self.load_vm('ibm-jdk-bin-1.5') + self.black = self.load_vm('blackdown-jdk-1.4.2') + + def test_empty_provide(self): + self.assertFalse(self.ibm.provides("foobar")) + + def test_name(self): + self.assertEqual(self.ibm.name(), 'ibm-jdk-bin-1.5') + + def test_is_build_only(self): + self.assertTrue(self.black.is_build_only()) + self.assertFalse(self.ibm.is_build_only()) + +if __name__ == '__main__': + unittest.main() + +# vim:set expandtab tabstop=4 shiftwidth=4 softtabstop=4 nowrap: diff --git a/tests/testsuite/VersionManager.py b/tests/testsuite/VersionManager.py new file mode 100644 index 0000000..c5c69bd --- /dev/null +++ b/tests/testsuite/VersionManager.py @@ -0,0 +1,107 @@ +import unittest +import os +from java_config_2.VersionManager import VersionManager +from java_config_2.EnvironmentManager import EnvironmentManager as em + +class TestVersionManager(unittest.TestCase): + verman = VersionManager() + + def setUp(self): + self.example_dep_vanilla = ">=virtual/jdk-1.5* dev-java/ant-core java-virtuals/jaf" + self.example_dep_or = "|| ( =virtual/jdk-1.5 =virtual/jdk-1.4 ) dev-java/ant-core java-virtuals/jaf" + self.example_dep_use = "java? ( >=virtual/jdk-1.5* ) dev-java/ant-core java-virtuals/jaf" + + self.example_slot_dep_vanilla = "virtual/jdk:1.5 dev-java/ant-core:0 java-virtuals/jaf:0" + self.example_slot_dep_or = "|| ( virtual/jdk:1.4 virtual/jdk:1.4 ) dev-java/ant-core:0 java-virtual/jaf:0" + self.example_slot_dep_use = "java? ( virtual/jdk:1.5 ) dev-java/ant-core:0 java-virtuals/jaf:0" + + def test_get_vm(self): + vm = self.verman.get_vm(">=virtual/jdk-1.5* java-virtuals/jaf") + self.assertEqual(vm.name(), 'sun-jdk-1.6') + + vm = self.verman.get_vm(">=virtual/jdk-1.5* java-virtuals/jaf:0") + self.assertEqual(vm.name(), 'sun-jdk-1.6') + + vm = self.verman.get_vm("virtual/jdk:1.5") + self.assertEqual(vm.name(), 'ibm-jdk-bin-1.5') + + self.assertRaises(Exception, self.verman.get_vm, 'virtual/jdk:1.4') + self.assertRaises(Exception, self.verman.get_vm, '=virtual/jdk-1.4*', False) + + vm = self.verman.get_vm('virtual/jdk:1.4', True) + self.assertTrue(vm.name(), 'blackdown-jdk-1.4.2') + + self.assertRaises(Exception, self.verman.get_vm, 'virtual/jdk:1.4 dev-java/test-package:0') + + def test_filter_depend_vanilla(self): + os.environ["USE"] = "" + self.assertEqual(self.verman.filter_depend(self.example_dep_vanilla), self.example_dep_vanilla) + + def test_filter_depend_or(self): + # Oh you only realise how ugly things are once you write unittests. + os.environ["USE"] = "" + rmatch = "|| =virtual/jdk-1.5 =virtual/jdk-1.4 dev-java/ant-core java-virtuals/jaf" + self.assertEqual(self.verman.filter_depend(self.example_dep_or), rmatch) + + def test_filter_depend_use(self): + os.environ["USE"] = "java" + rmatch = ">=virtual/jdk-1.5* dev-java/ant-core java-virtuals/jaf" + self.assertEqual(self.verman.filter_depend(self.example_dep_use), rmatch) + + def test_version_satisfies(self): + vm = em.get_vm('sun-jdk-1.6') + self.assertTrue(self.verman.version_satisfies('>=virtual/jdk-1.5', vm)) + self.assertFalse(self.verman.version_satisfies('>=virtual/jdk-1.7', vm)) + self.assertTrue(self.verman.version_satisfies('|| ( =virtual/jdk-1.6 =virtual/jdk-1.5 )', vm)) + + self.assertTrue(self.verman.version_satisfies('virtual/jdk:1.6', vm)) + self.assertFalse(self.verman.version_satisfies('virtual/jdk:1.5', vm)) + self.assertTrue(self.verman.version_satisfies('>=virtual/jdk-1.5', vm)) + + #this will be interesting from the perspective of environment handling. + + os.environ["USE"] = "java6" + self.assertTrue(self.verman.version_satisfies('java6? ( =virtual/jdk-1.6 )', vm)) + os.environ["USE"] = "" + self.assertFalse(self.verman.version_satisfies('java6? ( =virtual/jdk-1.6 ) !java6? ( =virtual/jdk-1.5 )', vm)) + + #def test_parse_depend(self): + + #def test_get_prefs(self): + + #def test_parse_depend_virtuals(self): + + #def test_get_lowest_atom(self): + + def test_get_lowest(self): + target = self.verman.get_lowest(">=virtual/jdk-1.4") + self.assertEqual(target, '1.4') + + target = self.verman.get_lowest(self.example_dep_vanilla) + self.assertEqual(target, '1.5') + + target = self.verman.get_lowest(self.example_dep_or) + self.assertEqual(target, '1.4') + + def test_get_lowest_with_package_dep(self): + pass + # 1.4 dep but ant-cores5 has a 1.8 target. + #self.assertRaises(Exception, self.verman.get_lowest, 'virtual/jdk:1.4 dev-java/test-package:0') + # 1.4 but has a 1.5 target package. + #self.assertRaises(Exception, self.verman.get_lowest, '>=virtual/jdk-1.4 dev-java/ant-cores5:0') + + #def test_find_vm(self): + + #def test_matches(self): + + def test_version_cmp(self): + self.assertEqual(self.verman.version_cmp('1.5.2', '1.5.2'), 0) + self.assertTrue(self.verman.version_cmp('1.5', '1.5.1') < 0) + self.assertTrue(self.verman.version_cmp('1.5.1', '1.5') > 0) + + #def test_matches(self): + +if __name__ == '__main__': + unittest.main() + +# vim:set expandtab tabstop=4 shiftwidth=4 softtabstop=4 nowrap: diff --git a/tests/testsuite/Virtual.py b/tests/testsuite/Virtual.py new file mode 100644 index 0000000..d511d64 --- /dev/null +++ b/tests/testsuite/Virtual.py @@ -0,0 +1,40 @@ +import unittest +import os +from java_config_2.Virtual import Virtual +from java_config_2.EnvironmentManager import EnvironmentManager as em +from java_config_2.Errors import ProviderUnavailableError + +def load_virtual(virtual): + config = os.path.join(TestVirtual.path, virtual) + return Virtual(virtual, em, config) + +class TestVirtual(unittest.TestCase): + path = os.path.join(os.path.dirname(__file__), "virtual_configs") + "/" + + def setUp(self): + self.jaf = load_virtual('jaf') + self.jmx = load_virtual('jmx') + self.jmx2 = load_virtual('jmx2') + + def test_get_vms(self): + self.assertEqual(self.jaf.get_vms(), ['sun-jdk-1.6']) + + def test_load_vms(self): + self.assertEqual( self.jmx._vms, ['ibm-jdk-bin-1.5', 'sun-jdk-1.6' , \ + 'sun-jdk-1.7', 'sun-jre-bin-1.6'] ) + self.assertEqual( self.jmx2._vms, ['ibm-jdk-bin-1.5', 'sun-jdk-1.6' , \ + 'sun-jdk-1.7', 'sun-jre-bin-1.6'] ) + +class TestMultiProviderVirtual(unittest.TestCase): + + def setUp(self): + em.set_active_vm(em.get_vm('sun-jdk-1.6')) + self.jdbc = load_virtual('jdbc') + + def test_classpath_multiple(self): + self.assertEqual( len(self.jdbc.classpath().split(':')), 2) + +if __name__ == '__main__': + unittest.main() + +# vim:set expandtab tabstop=4 shiftwidth=4 softtabstop=4 nowrap: diff --git a/tests/testsuite/__init__.py b/tests/testsuite/__init__.py new file mode 100644 index 0000000..d738781 --- /dev/null +++ b/tests/testsuite/__init__.py @@ -0,0 +1,13 @@ +__all__ = [ 'VM', 'Virtual', 'Package', 'VersionManager', 'EnvironmentManager' ] +from . import VM +from . import Virtual +from . import Package +from . import VersionManager +from . import EnvironmentManager +from java_config_2.EnvironmentManager import EnvironmentManager as em +em.vms_path = VM.TestVM.path +em.pkg_path = Package.TestPackage.path +em.virtual_path = Virtual.TestVirtual.path +em.set_active_vm(em.find_vm('ibm-jdk-bin-1.5')) + +# vim:set expandtab tabstop=4 shiftwidth=4 softtabstop=4 nowrap: diff --git a/tests/testsuite/packages/ant-cores/package.env b/tests/testsuite/packages/ant-cores/package.env new file mode 100644 index 0000000..ebda9b7 --- /dev/null +++ b/tests/testsuite/packages/ant-cores/package.env @@ -0,0 +1,10 @@ +DESCRIPTION="Description: ant-cores" +GENERATION="2" +SLOT="0" +CLASSPATH="/usr/share/ant-core/lib/ant.jar:/usr/share/ant-core/lib/ant-bootstrap.jar:/usr/share/ant-core/lib/ant-launcher.jar" +VM=">=virtual/jdk-1.4" +TARGET="1.4" +SOURCE="1.4" +JAVADOC_PATH="/usr/share/doc/ant-core-1.7.1-r2/html/api" +JAVA_SOURCES="/usr/share/ant-core/sources//ant-core-src.zip" +MERGE_VM="sun-jdk-1.7" diff --git a/tests/testsuite/packages/ant-cores5/package.env b/tests/testsuite/packages/ant-cores5/package.env new file mode 100644 index 0000000..9b378a9 --- /dev/null +++ b/tests/testsuite/packages/ant-cores5/package.env @@ -0,0 +1,10 @@ +DESCRIPTION="Description: ant-cores5" +GENERATION="2" +SLOT="0" +CLASSPATH="/usr/share/ant-core/lib/ant.jar:/usr/share/ant-core/lib/ant-bootstrap.jar:/usr/share/ant-core/lib/ant-launcher.jar" +VM=">=virtual/jdk-1.5" +TARGET="1.5" +SOURCE="1.5" +JAVADOC_PATH="/usr/share/doc/ant-core-1.7.1-r2/html/api" +JAVA_SOURCES="/usr/share/ant-core/sources//ant-core-src.zip" +MERGE_VM="sun-jdk-1.7" diff --git a/tests/testsuite/packages/commons-logging/package.env b/tests/testsuite/packages/commons-logging/package.env new file mode 100644 index 0000000..0226096 --- /dev/null +++ b/tests/testsuite/packages/commons-logging/package.env @@ -0,0 +1,11 @@ +DESCRIPTION="The Jakarta-Commons Logging package is an ultra-thin bridge between different logging libraries." +GENERATION="2" +SLOT="0" +CLASSPATH="/usr/share/commons-logging/lib/commons-logging.jar:/usr/share/commons-logging/lib/commons-logging-api.jar:/usr/share/commons-logging/lib/commons-logging-adapters.jar" +VM=">=virtual/jre-1.4" +TARGET="1.4" +SOURCE="1.4" +JAVADOC_PATH="/usr/share/doc/commons-logging-1.1.1/html/api" +JAVA_SOURCES="/usr/share/commons-logging/sources//commons-logging-src.zip" +MERGE_VM="sun-jdk-1.7" +MERGE_COMPILER="javac" diff --git a/tests/testsuite/packages/jdbc-mysql/package.env b/tests/testsuite/packages/jdbc-mysql/package.env new file mode 100644 index 0000000..1ec5d2f --- /dev/null +++ b/tests/testsuite/packages/jdbc-mysql/package.env @@ -0,0 +1,11 @@ +DESCRIPTION="MySQL JDBC driver" +GENERATION="2" +SLOT="0" +CLASSPATH="/usr/share/jdbc-mysql/lib/jdbc-mysql.jar" +DEPEND="commons-logging.jar@commons-logging:commons-logging-adapters.jar@commons-logging:commons-logging-api.jar@commons-logging:log4j.jar@log4j" +VM=">=virtual/jre-1.4" +TARGET="1.4" +SOURCE="1.4" +JAVA_SOURCES="/usr/share/jdbc-mysql/sources//jdbc-mysql-src.zip" +MERGE_VM="sun-jdk-1.5" +MERGE_COMPILER="javac" diff --git a/tests/testsuite/packages/jdbc-postgresql/package.env b/tests/testsuite/packages/jdbc-postgresql/package.env new file mode 100644 index 0000000..2beb488 --- /dev/null +++ b/tests/testsuite/packages/jdbc-postgresql/package.env @@ -0,0 +1,11 @@ +DESCRIPTION="JDBC Driver for PostgreSQL" +GENERATION="2" +SLOT="0" +CLASSPATH="/usr/share/jdbc-postgresql/lib/jdbc-postgresql.jar" +VM=">=virtual/jre-1.6" +TARGET="1.5" +SOURCE="1.5" +JAVADOC_PATH="/usr/share/doc/jdbc-postgresql-8.3_p603-r1/html/api" +JAVA_SOURCES="/usr/share/jdbc-postgresql/sources//jdbc-postgresql-src.zip" +MERGE_VM="sun-jdk-1.5" +MERGE_COMPILER="javac" diff --git a/tests/testsuite/packages/log4j/package.env b/tests/testsuite/packages/log4j/package.env new file mode 100644 index 0000000..ed19d32 --- /dev/null +++ b/tests/testsuite/packages/log4j/package.env @@ -0,0 +1,12 @@ +DESCRIPTION="A low-overhead robust logging package for Java" +GENERATION="2" +SLOT="0" +CLASSPATH="/usr/share/log4j/lib/log4j.jar" +DEPEND="" +VM=">=virtual/jre-1.4" +TARGET="1.4" +SOURCE="1.4" +JAVADOC_PATH="/usr/share/doc/log4j-1.2.15-r2/html/xref-test:/usr/share/doc/log4j-1.2.15-r2/html/xref:/usr/share/doc/log4j-1.2.15-r2/html/api" +JAVA_SOURCES="/usr/share/log4j/sources//log4j-src.zip" +MERGE_VM="sun-jdk-1.7" +MERGE_COMPILER="javac" diff --git a/tests/testsuite/packages/test-package/package.env b/tests/testsuite/packages/test-package/package.env new file mode 100644 index 0000000..193c715 --- /dev/null +++ b/tests/testsuite/packages/test-package/package.env @@ -0,0 +1,10 @@ +DESCRIPTION="Description: Test Package" +GENERATION="2" +SLOT="0" +CLASSPATH="/usr/share/ant-core/lib/ant.jar:/usr/share/ant-core/lib/ant-bootstrap.jar:/usr/share/ant-core/lib/ant-launcher.jar" +VM=">=virtual/jdk-1.8" +TARGET="1.8" +SOURCE="1.8" +JAVADOC_PATH="/usr/share/doc/ant-core-1.7.1-r2/html/api" +JAVA_SOURCES="/usr/share/ant-core/sources//ant-core-src.zip" +MERGE_VM="sun-jdk-1.8" diff --git a/tests/testsuite/virtual_configs/jaf b/tests/testsuite/virtual_configs/jaf new file mode 100644 index 0000000..1c5fc73 --- /dev/null +++ b/tests/testsuite/virtual_configs/jaf @@ -0,0 +1,2 @@ +PROVIDERS="sun-jaf gnu-jaf:1" +VM="sun-jdk-1.6 ibm-jdk-1.6" diff --git a/tests/testsuite/virtual_configs/jdbc b/tests/testsuite/virtual_configs/jdbc new file mode 100644 index 0000000..b34347d --- /dev/null +++ b/tests/testsuite/virtual_configs/jdbc @@ -0,0 +1,2 @@ +PROVIDERS="jdbc-postgresql jdbc-oracle-bin jdbc-mysql" +MULTI_PROVIDER="true" diff --git a/tests/testsuite/virtual_configs/jmx b/tests/testsuite/virtual_configs/jmx new file mode 100644 index 0000000..81fdbd7 --- /dev/null +++ b/tests/testsuite/virtual_configs/jmx @@ -0,0 +1,2 @@ +PROVIDERS="sun-jmx" +VM=">=virtual/jre-1.5 >=virtual/jdk-1.5" diff --git a/tests/testsuite/virtual_configs/jmx2 b/tests/testsuite/virtual_configs/jmx2 new file mode 100644 index 0000000..6d24b79 --- /dev/null +++ b/tests/testsuite/virtual_configs/jmx2 @@ -0,0 +1,2 @@ +PROVIDERS="sun-jmx" +VM=">=virtual/jre-1.5" diff --git a/tests/testsuite/vm_configs/blackdown-jdk-1.4.2 b/tests/testsuite/vm_configs/blackdown-jdk-1.4.2 new file mode 100644 index 0000000..3504f8e --- /dev/null +++ b/tests/testsuite/vm_configs/blackdown-jdk-1.4.2 @@ -0,0 +1,20 @@ +# Copyright 1999-2005 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-java/blackdown-jdk/files/blackdown-jdk-1.4.2.env,v 1.1 2006/06/25 16:47:40 nichoj Exp $ + +VERSION="Blackdown JDK 1.4.2.03" +JAVA_HOME=/opt/blackdown-jdk-1.4.2.03 +JDK_HOME=/opt/blackdown-jdk-1.4.2.03 +JAVAC=${JAVA_HOME}/bin/javac +PATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" +ROOTPATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" +LDPATH="${JAVA_HOME}/jre/lib/amd64/:${JAVA_HOME}/jre/lib/amd64/native_threads/:${JAVA_HOME}/jre/lib/amd64/classic/:${JAVA_HOME}/jre/lib/amd64/server/" +MANPATH=/opt/blackdown-jdk-1.4.2.03/man +PROVIDES_TYPE="JDK JRE" +PROVIDES_VERSION="1.4" +BOOTCLASSPATH="${JAVA_HOME}/jre/lib/rt.jar:${JAVA_HOME}/jre/lib/sunrsasign.jar:${JAVA_HOME}/jre/lib/jsse.jar:${JAVA_HOME}/jre/lib/jce.jar:${JAVA_HOME}/jre/lib/charsets.jar" +ENV_VARS="JAVA_HOME JDK_HOME JAVAC PATH ROOTPATH LDPATH MANPATH" +GENERATION="2" +VMHANDLE="blackdown-jdk-1.4.2" +PROVIDES="jdbc-stdext" +BUILD_ONLY="TRUE" diff --git a/tests/testsuite/vm_configs/ibm-jdk-bin-1.5 b/tests/testsuite/vm_configs/ibm-jdk-bin-1.5 new file mode 100644 index 0000000..20e30fc --- /dev/null +++ b/tests/testsuite/vm_configs/ibm-jdk-bin-1.5 @@ -0,0 +1,17 @@ +# Copyright 1999-2004 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-java/ibm-jdk-bin/files/ibm-jdk-bin-1.5.env,v 1.2 2007/12/12 15:10:08 caster Exp $ + +VERSION="IBM JDK 1.5.0.6" +JAVA_HOME=/opt/ibm-jdk-bin-1.5.0.6 +JDK_HOME=/opt/ibm-jdk-bin-1.5.0.6 +JAVAC=${JAVA_HOME}/bin/javac +PATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" +ROOTPATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" +LDPATH="/opt/ibm-jdk-bin-1.5.0.6/jre/bin/:/opt/ibm-jdk-bin-1.5.0.6/jre/bin/classic" +PROVIDES_TYPE="JDK JRE" +PROVIDES_VERSION="1.5" +BOOTCLASSPATH="${JAVA_HOME}/jre/lib/vm.jar:${JAVA_HOME}/jre/lib/core.jar:${JAVA_HOME}/jre/lib/charsets.jar:${JAVA_HOME}/jre/lib/graphics.jar:${JAVA_HOME}/jre/lib/security.jar:${JAVA_HOME}/jre/lib/ibmpkcs.jar:${JAVA_HOME}/jre/lib/ibmorb.jar:${JAVA_HOME}/jre/lib/ibmcfw.jar:${JAVA_HOME}/jre/lib/ibmorbapi.jar:${JAVA_HOME}/jre/lib/ibmjcefw.jar:${JAVA_HOME}/jre/lib/ibmjgssprovider.jar:${JAVA_HOME}/jre/lib/ibmjsseprovider2.jar:${JAVA_HOME}/jre/lib/ibmjaaslm.jar:${JAVA_HOME}/jre/lib/ibmcertpathprovider.jar:${JAVA_HOME}/jre/lib/server.jar:${JAVA_HOME}/jre/lib/xml.jar" +GENERATION="2" +ENV_VARS="JAVA_HOME JDK_HOME JAVAC PATH ROOTPATH LDPATH" +VMHANDLE="ibm-jdk-bin-1.5" diff --git a/tests/testsuite/vm_configs/sun-jdk-1.6 b/tests/testsuite/vm_configs/sun-jdk-1.6 new file mode 100644 index 0000000..501935e --- /dev/null +++ b/tests/testsuite/vm_configs/sun-jdk-1.6 @@ -0,0 +1,20 @@ +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-java/sun-jdk/files/sun-jdk-1.6.env,v 1.3 2007/04/30 11:03:14 betelgeuse Exp $ + +VERSION="Sun JDK 1.6.0.06" +JAVA_HOME=/opt/sun-jdk-1.6.0.06 +JDK_HOME=/opt/sun-jdk-1.6.0.06 +JAVAC=${JAVA_HOME}/bin/javac +PATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" +ROOTPATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" +LDPATH="${JAVA_HOME}/jre/lib/i386/:${JAVA_HOME}/jre/lib/i386/native_threads/:${JAVA_HOME}/jre/lib/i386/xawt/:${JAVA_HOME}/jre/lib/i386/server/" +MANPATH="/opt/sun-jdk-1.6.0.06/man" +PROVIDES_TYPE="JDK JRE" +PROVIDES_VERSION="1.6" +# Taken from sun.boot.class.path property +BOOTCLASSPATH="${JAVA_HOME}/jre/lib/resources.jar:${JAVA_HOME}/jre/lib/rt.jar:${JAVA_HOME}/jre/lib/jsse.jar:${JAVA_HOME}/jre/lib/jce.jar:${JAVA_HOME}/jre/lib/charsets.jar" +GENERATION="2" +ENV_VARS="JAVA_HOME JDK_HOME JAVAC PATH ROOTPATH LDPATH MANPATH" +VMHANDLE="sun-jdk-1.6" +PROVIDES="jdbc-stdext jdbc-rowset" diff --git a/tests/testsuite/vm_configs/sun-jdk-1.7 b/tests/testsuite/vm_configs/sun-jdk-1.7 new file mode 100644 index 0000000..71a5d5b --- /dev/null +++ b/tests/testsuite/vm_configs/sun-jdk-1.7 @@ -0,0 +1,19 @@ +# Copyright 1999-2005 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-java/sun-jdk/files/sun-jdk-1.5.env,v 1.1 2006/06/25 20:06:24 nichoj Exp $ + +VERSION="Sun JDK 1.7.0.0_alpha24" +JAVA_HOME=/opt/sun-jdk-1.7.0.0_alpha24 +JDK_HOME=/opt/sun-jdk-1.7.0.0_alpha24 +JAVAC=${JAVA_HOME}/bin/javac +PATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" +ROOTPATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" +LDPATH="${JAVA_HOME}/jre/lib/i386/:${JAVA_HOME}/jre/lib/i386/native_threads/:${JAVA_HOME}/jre/lib/i386/xawt/:${JAVA_HOME}/jre/lib/i386/server/" +MANPATH="/opt/sun-jdk-1.7.0.0_alpha24/man" +PROVIDES_TYPE="JDK JRE" +PROVIDES_VERSION="1.7" +BOOTCLASSPATH="${JAVA_HOME}/jre/lib/rt.jar:${JAVA_HOME}/jre/lib/i18n.jar:${JAVA_HOME}/jre/lib/sunrsasign.jar:${JAVA_HOME}/jre/lib/jsse.jar:${JAVA_HOME}/jre/lib/jce.jar:${JAVA_HOME}/jre/lib/charsets.jar" +GENERATION="2" +ENV_VARS="JAVA_HOME JDK_HOME JAVAC PATH ROOTPATH LDPATH MANPATH" +VMHANDLE="sun-jdk-1.7" +PROVIDES="jdbc-stdext jdbc-rowset" diff --git a/tests/testsuite/vm_configs/sun-jre-bin-1.6 b/tests/testsuite/vm_configs/sun-jre-bin-1.6 new file mode 100644 index 0000000..b9f6fdd --- /dev/null +++ b/tests/testsuite/vm_configs/sun-jre-bin-1.6 @@ -0,0 +1,19 @@ +# Copyright 1999-2005 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-java/sun-jre-bin/files/sun-jre-bin-1.6.env,v 1.2 2007/06/02 16:23:14 betelgeuse Exp $ + +VERSION="Sun JRE 1.6.0.13" +JAVA_HOME=/opt/sun-jre-bin-1.6.0.13 +JRE_HOME=/opt/sun-jre-bin-1.6.0.13 +PATH="${JAVA_HOME}/bin:${JAVA_HOME}/javaws" +ROOTPATH="${JAVA_HOME}/bin:${JAVA_HOME}/javaws" +LDPATH="${JAVA_HOME}/lib/amd64/:${JAVA_HOME}/lib/amd64/native_threads/:${JAVA_HOME}/lib/amd64/xawt/:${JAVA_HOME}/lib/amd64/server/" +MANPATH="/opt/sun-jre-bin-1.6.0.13/man" +PROVIDES_TYPE="JRE" +PROVIDES_VERSION="1.6" +# Taken from sun.boot.class.path property +BOOTCLASSPATH="${JAVA_HOME}/jre/lib/resources.jar:${JAVA_HOME}/jre/lib/rt.jar:${JAVA_HOME}/jre/lib/jsse.jar:${JAVA_HOME}/jre/lib/jce.jar:${JAVA_HOME}/jre/lib/charsets.jar" +GENERATION="2" +ENV_VARS="JAVA_HOME JRE_HOME PATH ROOTPATH LDPATH MANPATH" +VMHANDLE="sun-jre-bin-1.6" +PROVIDES="jdbc-stdext jdbc-rowset" diff --git a/tests/testsuite2/VersionManager.py b/tests/testsuite2/VersionManager.py new file mode 100644 index 0000000..c578dc1 --- /dev/null +++ b/tests/testsuite2/VersionManager.py @@ -0,0 +1,16 @@ +import unittest +import os +from java_config_2.VersionManager import VersionManager +from java_config_2.EnvironmentManager import EnvironmentManager as em + +class TestVersionManager(unittest.TestCase): + verman = VersionManager() + + def test_get_vm(self): + vm = self.verman.get_vm("virtual/jdk:1.6 java-virtuals/jdk-with-com-sun dev-java/ant-contrib:0 app-arch/xz-utils >=dev-java/java-config-2.1.9-r1 source? ( app-arch/zip ) >=dev-java/ant-core-1.7.0 dev-java/ant-nodeps >=dev-java/javatoolkit-0.3.0-r2 >=dev-lang/python-2.4") + self.assertEqual(vm.name(), 'icedtea-bin-6') + +if __name__ == '__main__': + unittest.main() + +# vim:set expandtab tabstop=4 shiftwidth=4 softtabstop=4 nowrap: diff --git a/tests/testsuite2/__init__.py b/tests/testsuite2/__init__.py new file mode 100644 index 0000000..cd19d07 --- /dev/null +++ b/tests/testsuite2/__init__.py @@ -0,0 +1,10 @@ +__all__ = [ 'VersionManager' ] +from . import VersionManager +import os +from java_config_2.EnvironmentManager import EnvironmentManager as em +em.vms_path = os.path.join(os.path.dirname(__file__), 'vm_configs') +em.pkg_path = path = os.path.join(os.path.dirname(__file__), 'packages', '%s/package.env') +em.virtual_path = os.path.join(os.path.dirname(__file__), 'virtual_configs') + '/' +em.set_active_vm(em.find_vm('icedtea-bin-7')[0]) + +# vim:set expandtab tabstop=4 shiftwidth=4 softtabstop=4 nowrap: diff --git a/tests/testsuite2/packages/ant-contrib/package.env b/tests/testsuite2/packages/ant-contrib/package.env new file mode 100644 index 0000000..280d765 --- /dev/null +++ b/tests/testsuite2/packages/ant-contrib/package.env @@ -0,0 +1,12 @@ +DESCRIPTION="A collection of tasks (and at one point maybe types and other tools) for Apache Ant." +GENERATION="2" +SLOT="0" +CATEGORY="dev-java" +PVR="1.0_beta3" +CLASSPATH="/usr/share/ant-contrib/lib/ant-contrib.jar" +DEPEND="ant-core:ant-ivy:bcel:commons-httpclient-3:xerces-2" +VM=">=virtual/jre-1.4" +TARGET="1.4" +SOURCE="1.4" +MERGE_VM="icedtea6-bin" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/ant-core/package.env b/tests/testsuite2/packages/ant-core/package.env new file mode 100644 index 0000000..150b426 --- /dev/null +++ b/tests/testsuite2/packages/ant-core/package.env @@ -0,0 +1,10 @@ +DESCRIPTION="Java-based build tool similar to 'make' that uses XML configuration files." +GENERATION="2" +SLOT="0" +CATEGORY="dev-java" +PVR="1.8.2" +CLASSPATH="/usr/share/ant-core/lib/ant.jar:/usr/share/ant-core/lib/ant-bootstrap.jar:/usr/share/ant-core/lib/ant-launcher.jar" +VM=">=virtual/jdk-1.4" +TARGET="1.4" +SOURCE="1.4" +MERGE_VM="icedtea-bin-7" diff --git a/tests/testsuite2/packages/ant-ivy/package.env b/tests/testsuite2/packages/ant-ivy/package.env new file mode 100644 index 0000000..9b1c515 --- /dev/null +++ b/tests/testsuite2/packages/ant-ivy/package.env @@ -0,0 +1,12 @@ +DESCRIPTION="Ivy is a free java based dependency manager" +GENERATION="2" +SLOT="0" +CATEGORY="dev-java" +PVR="1.4.1" +CLASSPATH="/usr/share/ant-ivy/lib/ivy.jar" +DEPEND="ant-core:commons-cli-1:commons-httpclient-3:commons-vfs:jakarta-oro-2.0:jsch" +VM=">=virtual/jre-1.4" +TARGET="1.4" +SOURCE="1.4" +MERGE_VM="icedtea6-bin" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/ant-nodeps/package.env b/tests/testsuite2/packages/ant-nodeps/package.env new file mode 100644 index 0000000..1dcdd72 --- /dev/null +++ b/tests/testsuite2/packages/ant-nodeps/package.env @@ -0,0 +1,11 @@ +DESCRIPTION="Apache Ant's optional tasks requiring no external deps" +GENERATION="2" +SLOT="0" +CATEGORY="dev-java" +PVR="1.8.2" +CLASSPATH="/usr/share/ant-nodeps/lib/ant-nodeps.jar" +VM=">=virtual/jre-1.4" +BUILD_DEPEND="ant.jar@ant.jar" +TARGET="1.4" +SOURCE="1.4" +MERGE_VM="icedtea-bin-7" diff --git a/tests/testsuite2/packages/bcel/package.env b/tests/testsuite2/packages/bcel/package.env new file mode 100644 index 0000000..cfd64ce --- /dev/null +++ b/tests/testsuite2/packages/bcel/package.env @@ -0,0 +1,11 @@ +DESCRIPTION="The Byte Code Engineering Library: analyze, create, manipulate Java class files" +GENERATION="2" +SLOT="0" +CATEGORY="dev-java" +PVR="5.2-r2" +CLASSPATH="/usr/share/bcel/lib/bcel.jar" +VM=">=virtual/jre-1.5" +TARGET="1.5" +SOURCE="1.5" +MERGE_VM="icedtea6-bin" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/commons-cli-1/package.env b/tests/testsuite2/packages/commons-cli-1/package.env new file mode 100644 index 0000000..1bd8d5a --- /dev/null +++ b/tests/testsuite2/packages/commons-cli-1/package.env @@ -0,0 +1,11 @@ +DESCRIPTION="A Java library for working with the command line arguments and options." +GENERATION="2" +SLOT="1" +CATEGORY="dev-java" +PVR="1.2" +CLASSPATH="/usr/share/commons-cli-1/lib/commons-cli.jar" +VM=">=virtual/jre-1.4" +TARGET="1.4" +SOURCE="1.4" +MERGE_VM="icedtea6-bin" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/commons-codec/package.env b/tests/testsuite2/packages/commons-codec/package.env new file mode 100644 index 0000000..3e3064d --- /dev/null +++ b/tests/testsuite2/packages/commons-codec/package.env @@ -0,0 +1,11 @@ +DESCRIPTION="Implementations of common encoders and decoders in Java." +GENERATION="2" +SLOT="0" +CATEGORY="dev-java" +PVR="1.4" +CLASSPATH="/usr/share/commons-codec/lib/commons-codec.jar" +VM=">=virtual/jre-1.4" +TARGET="1.4" +SOURCE="1.4" +MERGE_VM="icedtea6-bin" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/commons-collections/package.env b/tests/testsuite2/packages/commons-collections/package.env new file mode 100644 index 0000000..67c835d --- /dev/null +++ b/tests/testsuite2/packages/commons-collections/package.env @@ -0,0 +1,11 @@ +DESCRIPTION="Jakarta-Commons Collections Component" +GENERATION="2" +SLOT="0" +CATEGORY="dev-java" +PVR="3.2.1" +CLASSPATH="/usr/share/commons-collections/lib/commons-collections.jar" +VM=">=virtual/jre-1.4" +TARGET="1.4" +SOURCE="1.4" +MERGE_VM="icedtea6-bin" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/commons-httpclient-3/package.env b/tests/testsuite2/packages/commons-httpclient-3/package.env new file mode 100644 index 0000000..c437e98 --- /dev/null +++ b/tests/testsuite2/packages/commons-httpclient-3/package.env @@ -0,0 +1,12 @@ +DESCRIPTION="The Jakarta Commons HttpClient library" +GENERATION="2" +SLOT="3" +CATEGORY="dev-java" +PVR="3.1" +CLASSPATH="/usr/share/commons-httpclient-3/lib/commons-httpclient.jar" +DEPEND="commons-codec.jar@commons-codec:commons-logging-adapters.jar@commons-logging:commons-logging-api.jar@commons-logging:commons-logging.jar@commons-logging" +VM=">=virtual/jre-1.4" +TARGET="1.4" +SOURCE="1.4" +MERGE_VM="icedtea6-bin" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/commons-logging/package.env b/tests/testsuite2/packages/commons-logging/package.env new file mode 100644 index 0000000..25115dd --- /dev/null +++ b/tests/testsuite2/packages/commons-logging/package.env @@ -0,0 +1,11 @@ +DESCRIPTION="The Jakarta-Commons Logging package is an ultra-thin bridge between different logging libraries." +GENERATION="2" +SLOT="0" +CATEGORY="dev-java" +PVR="1.1.1" +CLASSPATH="/usr/share/commons-logging/lib/commons-logging.jar:/usr/share/commons-logging/lib/commons-logging-api.jar:/usr/share/commons-logging/lib/commons-logging-adapters.jar" +VM=">=virtual/jre-1.4" +TARGET="1.4" +SOURCE="1.4" +MERGE_VM="icedtea6-bin" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/commons-net/package.env b/tests/testsuite2/packages/commons-net/package.env new file mode 100644 index 0000000..1388398 --- /dev/null +++ b/tests/testsuite2/packages/commons-net/package.env @@ -0,0 +1,12 @@ +DESCRIPTION="The purpose of the library is to provide fundamental protocol access, not higher-level abstractions." +GENERATION="2" +SLOT="0" +CATEGORY="dev-java" +PVR="1.4.1-r1" +CLASSPATH="/usr/share/commons-net/lib/commons-net.jar" +DEPEND="jakarta-oro.jar@jakarta-oro-2.0" +VM=">=virtual/jre-1.3" +TARGET="1.3" +SOURCE="1.3" +MERGE_VM="icedtea6-bin" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/commons-vfs/package.env b/tests/testsuite2/packages/commons-vfs/package.env new file mode 100644 index 0000000..26b2391 --- /dev/null +++ b/tests/testsuite2/packages/commons-vfs/package.env @@ -0,0 +1,12 @@ +DESCRIPTION="a single API for accessing various different file systems" +GENERATION="2" +SLOT="0" +CATEGORY="dev-java" +PVR="1.0" +CLASSPATH="/usr/share/commons-vfs/lib/commons-vfs.jar" +DEPEND="ant-core:commons-collections:commons-httpclient-3:commons-logging:commons-net:jsch" +VM=">=virtual/jre-1.4" +TARGET="1.4" +SOURCE="1.4" +MERGE_VM="icedtea6-bin" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/jakarta-oro-2.0/package.env b/tests/testsuite2/packages/jakarta-oro-2.0/package.env new file mode 100644 index 0000000..6806fbe --- /dev/null +++ b/tests/testsuite2/packages/jakarta-oro-2.0/package.env @@ -0,0 +1,11 @@ +DESCRIPTION="A set of text-processing Java classes." +GENERATION="2" +SLOT="2.0" +CATEGORY="dev-java" +PVR="2.0.8-r3" +CLASSPATH="/usr/share/jakarta-oro-2.0/lib/jakarta-oro.jar" +VM=">=virtual/jre-1.3" +TARGET="1.3" +SOURCE="1.3" +MERGE_VM="icedtea-bin-7" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/jsch/package.env b/tests/testsuite2/packages/jsch/package.env new file mode 100644 index 0000000..6cf0193 --- /dev/null +++ b/tests/testsuite2/packages/jsch/package.env @@ -0,0 +1,12 @@ +DESCRIPTION="JSch is a pure Java implementation of SSH2." +GENERATION="2" +SLOT="0" +CATEGORY="dev-java" +PVR="0.1.44" +CLASSPATH="/usr/share/jsch/lib/jsch.jar" +DEPEND="jzlib" +VM=">=virtual/jdk-1.5" +TARGET="1.5" +SOURCE="1.5" +MERGE_VM="icedtea6-bin" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/jzlib/package.env b/tests/testsuite2/packages/jzlib/package.env new file mode 100644 index 0000000..fb1d810 --- /dev/null +++ b/tests/testsuite2/packages/jzlib/package.env @@ -0,0 +1,11 @@ +DESCRIPTION="JZlib is a re-implementation of zlib in pure Java." +GENERATION="2" +SLOT="0" +CATEGORY="dev-java" +PVR="1.0.7-r1" +CLASSPATH="/usr/share/jzlib/lib/jzlib.jar" +VM=">=virtual/jre-1.4" +TARGET="1.4" +SOURCE="1.4" +MERGE_VM="icedtea6-bin" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/xerces-2/package.env b/tests/testsuite2/packages/xerces-2/package.env new file mode 100644 index 0000000..06f637c --- /dev/null +++ b/tests/testsuite2/packages/xerces-2/package.env @@ -0,0 +1,12 @@ +DESCRIPTION="The next generation of high performance, fully compliant XML parsers in the Apache Xerces family" +GENERATION="2" +SLOT="2" +CATEGORY="dev-java" +PVR="2.11.0" +CLASSPATH="/usr/share/xerces-2/lib/xercesImpl.jar" +DEPEND="xml-commons-external-1.4:xml-commons-resolver" +VM=">=virtual/jre-1.4" +TARGET="1.4" +SOURCE="1.4" +MERGE_VM="icedtea-bin-7" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/xml-commons-external-1.4/package.env b/tests/testsuite2/packages/xml-commons-external-1.4/package.env new file mode 100644 index 0000000..2b8d8e4 --- /dev/null +++ b/tests/testsuite2/packages/xml-commons-external-1.4/package.env @@ -0,0 +1,11 @@ +DESCRIPTION="An Apache-hosted set of externally-defined standards interfaces, namely DOM, SAX, and JAXP." +GENERATION="2" +SLOT="1.4" +CATEGORY="dev-java" +PVR="1.4.01" +CLASSPATH="/usr/share/xml-commons-external-1.4/lib/xml-apis.jar:/usr/share/xml-commons-external-1.4/lib/xml-apis-ext.jar" +VM=">=virtual/jre-1.3" +TARGET="1.3" +SOURCE="1.3" +MERGE_VM="icedtea-bin-7" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/packages/xml-commons-resolver/package.env b/tests/testsuite2/packages/xml-commons-resolver/package.env new file mode 100644 index 0000000..6caae64 --- /dev/null +++ b/tests/testsuite2/packages/xml-commons-resolver/package.env @@ -0,0 +1,11 @@ +DESCRIPTION="An XML Entity and URI Resolver" +GENERATION="2" +SLOT="0" +CATEGORY="dev-java" +PVR="1.2" +CLASSPATH="/usr/share/xml-commons-resolver/lib/xml-commons-resolver.jar" +VM=">=virtual/jre-1.3" +TARGET="1.3" +SOURCE="1.3" +MERGE_VM="icedtea6-bin" +MERGE_COMPILER="javac" diff --git a/tests/testsuite2/virtual_configs/jdk-with-com-sun b/tests/testsuite2/virtual_configs/jdk-with-com-sun new file mode 100644 index 0000000..13fd0ef --- /dev/null +++ b/tests/testsuite2/virtual_configs/jdk-with-com-sun @@ -0,0 +1,2 @@ +VM="icedtea-bin-6 icedtea6-bin icedtea-6 icedtea6 icedtea-bin-6 icedtea-bin-7 icedtea-7 sun-jdk-1.6 sun-jdk-1.5 sun-jdk-1.4 oracle-jdk-bin-1.7 diablo-jdk-1.6 apple-jdk-bin-1.6 apple-jdk-bin-1.5 apple-jdk-bin-1.4" +MULTI_PROVIDER="FALSE" diff --git a/tests/testsuite2/vm_configs/icedtea-7 b/tests/testsuite2/vm_configs/icedtea-7 new file mode 100644 index 0000000..69223c4 --- /dev/null +++ b/tests/testsuite2/vm_configs/icedtea-7 @@ -0,0 +1,20 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-java/icedtea/files/icedtea.env,v 1.3 2011/11/28 15:29:59 sera Exp $ + +VERSION="IcedTea JDK 7.2.1" +JAVA_HOME="/usr/lib64/icedtea7" +JDK_HOME="/usr/lib64/icedtea7" +JAVAC="${JAVA_HOME}/bin/javac" +PATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" +ROOTPATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" +LDPATH="${JAVA_HOME}/jre/lib/amd64/:${JAVA_HOME}/jre/lib/amd64/native_threads/:${JAVA_HOME}/jre/lib/amd64/xawt/:${JAVA_HOME}/jre/lib/amd64/server/" +MANPATH="/usr/lib64/icedtea7/man" +PROVIDES_TYPE="JDK JRE" +PROVIDES_VERSION="1.7" +# Taken from sun.boot.class.path property +BOOTCLASSPATH="${JAVA_HOME}/jre/lib/resources.jar:${JAVA_HOME}/jre/lib/rt.jar:${JAVA_HOME}/jre/lib/jsse.jar:${JAVA_HOME}/jre/lib/jce.jar:${JAVA_HOME}/jre/lib/charsets.jar" +GENERATION="2" +ENV_VARS="JAVA_HOME JDK_HOME JAVAC PATH ROOTPATH LDPATH MANPATH" +VMHANDLE="icedtea-7" +BUILD_ONLY="FALSE" diff --git a/tests/testsuite2/vm_configs/icedtea-bin-6 b/tests/testsuite2/vm_configs/icedtea-bin-6 new file mode 100644 index 0000000..d0104c7 --- /dev/null +++ b/tests/testsuite2/vm_configs/icedtea-bin-6 @@ -0,0 +1,20 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-java/icedtea-bin/files/icedtea-bin-6.env,v 1.2 2011/11/28 14:01:54 sera Exp $ + +VERSION="IcedTea JDK 6.1.11.1" +JAVA_HOME="/opt/icedtea-bin-6.1.11.1" +JDK_HOME="/opt/icedtea-bin-6.1.11.1" +JAVAC="${JAVA_HOME}/bin/javac" +PATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" +ROOTPATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" +LDPATH="${JAVA_HOME}/jre/lib/amd64/:${JAVA_HOME}/jre/lib/amd64/native_threads/:${JAVA_HOME}/jre/lib/amd64/xawt/:${JAVA_HOME}/jre/lib/amd64/server/" +MANPATH="/opt/icedtea-bin-6.1.11.1/man" +PROVIDES_TYPE="JDK JRE" +PROVIDES_VERSION="1.6" +# Taken from sun.boot.class.path property +BOOTCLASSPATH="${JAVA_HOME}/jre/lib/resources.jar:${JAVA_HOME}/jre/lib/rt.jar:${JAVA_HOME}/jre/lib/jsse.jar:${JAVA_HOME}/jre/lib/jce.jar:${JAVA_HOME}/jre/lib/charsets.jar" +GENERATION="2" +ENV_VARS="JAVA_HOME JDK_HOME JAVAC PATH ROOTPATH LDPATH MANPATH" +VMHANDLE="icedtea-bin-6" +BUILD_ONLY="FALSE" diff --git a/tests/testsuite2/vm_configs/icedtea-bin-7 b/tests/testsuite2/vm_configs/icedtea-bin-7 new file mode 100644 index 0000000..01e4027 --- /dev/null +++ b/tests/testsuite2/vm_configs/icedtea-bin-7 @@ -0,0 +1,20 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-java/icedtea-bin/files/icedtea-bin-7.env,v 1.2 2011/11/28 14:01:54 sera Exp $ + +VERSION="IcedTea JDK 7.2.1" +JAVA_HOME="/opt/icedtea-bin-7.2.1" +JDK_HOME="/opt/icedtea-bin-7.2.1" +JAVAC="${JAVA_HOME}/bin/javac" +PATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" +ROOTPATH="${JAVA_HOME}/bin:${JAVA_HOME}/jre/bin" +LDPATH="${JAVA_HOME}/jre/lib/amd64/:${JAVA_HOME}/jre/lib/amd64/native_threads/:${JAVA_HOME}/jre/lib/amd64/xawt/:${JAVA_HOME}/jre/lib/amd64/server/" +MANPATH="/opt/icedtea-bin-7.2.1/man" +PROVIDES_TYPE="JDK JRE" +PROVIDES_VERSION="1.7" +# Taken from sun.boot.class.path property +BOOTCLASSPATH="${JAVA_HOME}/jre/lib/resources.jar:${JAVA_HOME}/jre/lib/rt.jar:${JAVA_HOME}/jre/lib/jsse.jar:${JAVA_HOME}/jre/lib/jce.jar:${JAVA_HOME}/jre/lib/charsets.jar" +GENERATION="2" +ENV_VARS="JAVA_HOME JDK_HOME JAVAC PATH ROOTPATH LDPATH MANPATH" +VMHANDLE="icedtea-bin-7" +BUILD_ONLY="FALSE" |