aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorRalph Sennhauser <sera@gentoo.org>2013-02-10 10:00:24 +0000
committerRalph Sennhauser <sera@gentoo.org>2013-02-10 10:00:24 +0000
commitd2b7f2c80e7086f94910f37f6762691ee09a5f3c (patch)
treedaef37229b12a5b8e1e6e33f2d4bcfbedaacafc9 /tests
parentUse new ROOT support in EnvironmentManager for testsuite (diff)
downloadjava-config-d2b7f2c80e7086f94910f37f6762691ee09a5f3c.tar.gz
java-config-d2b7f2c80e7086f94910f37f6762691ee09a5f3c.tar.bz2
java-config-d2b7f2c80e7086f94910f37f6762691ee09a5f3c.zip
Merge testsuite2 into testsuite and use new ROOT support in EnvironmentManager
svn path=/projects/java-config-2/trunk/; revision=9187
Diffstat (limited to 'tests')
-rw-r--r--tests/run-test-suite2.py8
-rwxr-xr-xtests/test2.sh2
-rw-r--r--tests/testsuite/VersionManagerEnv2.py (renamed from tests/testsuite2/VersionManager.py)12
-rw-r--r--tests/testsuite/__init__.py3
-rw-r--r--tests/testsuite/test_env2/etc/java-config-2/virtuals0
-rw-r--r--tests/testsuite/test_env2/usr/share/ant-contrib/package.env (renamed from tests/testsuite2/packages/ant-contrib/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/ant-core/package.env (renamed from tests/testsuite2/packages/ant-core/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/ant-ivy/package.env (renamed from tests/testsuite2/packages/ant-ivy/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/ant-nodeps/package.env (renamed from tests/testsuite2/packages/ant-nodeps/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/bcel/package.env (renamed from tests/testsuite2/packages/bcel/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/commons-cli-1/package.env (renamed from tests/testsuite2/packages/commons-cli-1/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/commons-codec/package.env (renamed from tests/testsuite2/packages/commons-codec/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/commons-collections/package.env (renamed from tests/testsuite2/packages/commons-collections/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/commons-httpclient-3/package.env (renamed from tests/testsuite2/packages/commons-httpclient-3/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/commons-logging/package.env (renamed from tests/testsuite2/packages/commons-logging/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/commons-net/package.env (renamed from tests/testsuite2/packages/commons-net/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/commons-vfs/package.env (renamed from tests/testsuite2/packages/commons-vfs/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/jakarta-oro-2.0/package.env (renamed from tests/testsuite2/packages/jakarta-oro-2.0/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/java-config-2/virtuals/jdk-with-com-sun (renamed from tests/testsuite2/virtual_configs/jdk-with-com-sun)0
-rw-r--r--tests/testsuite/test_env2/usr/share/java-config-2/vm/icedtea-7 (renamed from tests/testsuite2/vm_configs/icedtea-7)0
-rw-r--r--tests/testsuite/test_env2/usr/share/java-config-2/vm/icedtea-bin-6 (renamed from tests/testsuite2/vm_configs/icedtea-bin-6)0
-rw-r--r--tests/testsuite/test_env2/usr/share/java-config-2/vm/icedtea-bin-7 (renamed from tests/testsuite2/vm_configs/icedtea-bin-7)0
-rw-r--r--tests/testsuite/test_env2/usr/share/jsch/package.env (renamed from tests/testsuite2/packages/jsch/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/jzlib/package.env (renamed from tests/testsuite2/packages/jzlib/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/xerces-2/package.env (renamed from tests/testsuite2/packages/xerces-2/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/xml-commons-external-1.4/package.env (renamed from tests/testsuite2/packages/xml-commons-external-1.4/package.env)0
-rw-r--r--tests/testsuite/test_env2/usr/share/xml-commons-resolver/package.env (renamed from tests/testsuite2/packages/xml-commons-resolver/package.env)0
-rw-r--r--tests/testsuite2/__init__.py10
28 files changed, 10 insertions, 25 deletions
diff --git a/tests/run-test-suite2.py b/tests/run-test-suite2.py
deleted file mode 100644
index a386268..0000000
--- a/tests/run-test-suite2.py
+++ /dev/null
@@ -1,8 +0,0 @@
-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/test2.sh b/tests/test2.sh
deleted file mode 100755
index 149ce3c..0000000
--- a/tests/test2.sh
+++ /dev/null
@@ -1,2 +0,0 @@
-#!/bin/sh
-PYTHONPATH="../src" python "`dirname $0`"/run-test-suite2.py
diff --git a/tests/testsuite2/VersionManager.py b/tests/testsuite/VersionManagerEnv2.py
index 3b5b3ac..b32438e 100644
--- a/tests/testsuite2/VersionManager.py
+++ b/tests/testsuite/VersionManagerEnv2.py
@@ -1,10 +1,14 @@
-import unittest
-import os
+import os, unittest
+
from java_config_2.VersionManager import VersionManager
from java_config_2.EnvironmentManager import EnvironmentManager
-class TestVersionManager(unittest.TestCase):
- verman = VersionManager(EnvironmentManager())
+class TestVersionManagerEnv2(unittest.TestCase):
+
+ def setUp(self):
+ self.em = EnvironmentManager(os.path.join(os.path.dirname(__file__), 'test_env2'))
+ self.em.set_active_vm(self.em.find_vm('icedtea-bin-6'))
+ self.verman = VersionManager(self.em)
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")
diff --git a/tests/testsuite/__init__.py b/tests/testsuite/__init__.py
index 06c70e0..bd9e014 100644
--- a/tests/testsuite/__init__.py
+++ b/tests/testsuite/__init__.py
@@ -1,8 +1,9 @@
-__all__ = [ 'VM', 'Virtual', 'Package', 'VersionManager', 'EnvironmentManager' ]
+__all__ = [ 'VM', 'Virtual', 'Package', 'VersionManager', 'VersionManagerEnv2', 'EnvironmentManager' ]
from . import VM
from . import Virtual
from . import Package
from . import VersionManager
+from . import VersionManagerEnv2
from . import EnvironmentManager
# vim:set expandtab tabstop=4 shiftwidth=4 softtabstop=4 nowrap:
diff --git a/tests/testsuite/test_env2/etc/java-config-2/virtuals b/tests/testsuite/test_env2/etc/java-config-2/virtuals
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/tests/testsuite/test_env2/etc/java-config-2/virtuals
diff --git a/tests/testsuite2/packages/ant-contrib/package.env b/tests/testsuite/test_env2/usr/share/ant-contrib/package.env
index 280d765..280d765 100644
--- a/tests/testsuite2/packages/ant-contrib/package.env
+++ b/tests/testsuite/test_env2/usr/share/ant-contrib/package.env
diff --git a/tests/testsuite2/packages/ant-core/package.env b/tests/testsuite/test_env2/usr/share/ant-core/package.env
index 150b426..150b426 100644
--- a/tests/testsuite2/packages/ant-core/package.env
+++ b/tests/testsuite/test_env2/usr/share/ant-core/package.env
diff --git a/tests/testsuite2/packages/ant-ivy/package.env b/tests/testsuite/test_env2/usr/share/ant-ivy/package.env
index 9b1c515..9b1c515 100644
--- a/tests/testsuite2/packages/ant-ivy/package.env
+++ b/tests/testsuite/test_env2/usr/share/ant-ivy/package.env
diff --git a/tests/testsuite2/packages/ant-nodeps/package.env b/tests/testsuite/test_env2/usr/share/ant-nodeps/package.env
index 1dcdd72..1dcdd72 100644
--- a/tests/testsuite2/packages/ant-nodeps/package.env
+++ b/tests/testsuite/test_env2/usr/share/ant-nodeps/package.env
diff --git a/tests/testsuite2/packages/bcel/package.env b/tests/testsuite/test_env2/usr/share/bcel/package.env
index cfd64ce..cfd64ce 100644
--- a/tests/testsuite2/packages/bcel/package.env
+++ b/tests/testsuite/test_env2/usr/share/bcel/package.env
diff --git a/tests/testsuite2/packages/commons-cli-1/package.env b/tests/testsuite/test_env2/usr/share/commons-cli-1/package.env
index 1bd8d5a..1bd8d5a 100644
--- a/tests/testsuite2/packages/commons-cli-1/package.env
+++ b/tests/testsuite/test_env2/usr/share/commons-cli-1/package.env
diff --git a/tests/testsuite2/packages/commons-codec/package.env b/tests/testsuite/test_env2/usr/share/commons-codec/package.env
index 3e3064d..3e3064d 100644
--- a/tests/testsuite2/packages/commons-codec/package.env
+++ b/tests/testsuite/test_env2/usr/share/commons-codec/package.env
diff --git a/tests/testsuite2/packages/commons-collections/package.env b/tests/testsuite/test_env2/usr/share/commons-collections/package.env
index 67c835d..67c835d 100644
--- a/tests/testsuite2/packages/commons-collections/package.env
+++ b/tests/testsuite/test_env2/usr/share/commons-collections/package.env
diff --git a/tests/testsuite2/packages/commons-httpclient-3/package.env b/tests/testsuite/test_env2/usr/share/commons-httpclient-3/package.env
index c437e98..c437e98 100644
--- a/tests/testsuite2/packages/commons-httpclient-3/package.env
+++ b/tests/testsuite/test_env2/usr/share/commons-httpclient-3/package.env
diff --git a/tests/testsuite2/packages/commons-logging/package.env b/tests/testsuite/test_env2/usr/share/commons-logging/package.env
index 25115dd..25115dd 100644
--- a/tests/testsuite2/packages/commons-logging/package.env
+++ b/tests/testsuite/test_env2/usr/share/commons-logging/package.env
diff --git a/tests/testsuite2/packages/commons-net/package.env b/tests/testsuite/test_env2/usr/share/commons-net/package.env
index 1388398..1388398 100644
--- a/tests/testsuite2/packages/commons-net/package.env
+++ b/tests/testsuite/test_env2/usr/share/commons-net/package.env
diff --git a/tests/testsuite2/packages/commons-vfs/package.env b/tests/testsuite/test_env2/usr/share/commons-vfs/package.env
index 26b2391..26b2391 100644
--- a/tests/testsuite2/packages/commons-vfs/package.env
+++ b/tests/testsuite/test_env2/usr/share/commons-vfs/package.env
diff --git a/tests/testsuite2/packages/jakarta-oro-2.0/package.env b/tests/testsuite/test_env2/usr/share/jakarta-oro-2.0/package.env
index 6806fbe..6806fbe 100644
--- a/tests/testsuite2/packages/jakarta-oro-2.0/package.env
+++ b/tests/testsuite/test_env2/usr/share/jakarta-oro-2.0/package.env
diff --git a/tests/testsuite2/virtual_configs/jdk-with-com-sun b/tests/testsuite/test_env2/usr/share/java-config-2/virtuals/jdk-with-com-sun
index 13fd0ef..13fd0ef 100644
--- a/tests/testsuite2/virtual_configs/jdk-with-com-sun
+++ b/tests/testsuite/test_env2/usr/share/java-config-2/virtuals/jdk-with-com-sun
diff --git a/tests/testsuite2/vm_configs/icedtea-7 b/tests/testsuite/test_env2/usr/share/java-config-2/vm/icedtea-7
index 69223c4..69223c4 100644
--- a/tests/testsuite2/vm_configs/icedtea-7
+++ b/tests/testsuite/test_env2/usr/share/java-config-2/vm/icedtea-7
diff --git a/tests/testsuite2/vm_configs/icedtea-bin-6 b/tests/testsuite/test_env2/usr/share/java-config-2/vm/icedtea-bin-6
index d0104c7..d0104c7 100644
--- a/tests/testsuite2/vm_configs/icedtea-bin-6
+++ b/tests/testsuite/test_env2/usr/share/java-config-2/vm/icedtea-bin-6
diff --git a/tests/testsuite2/vm_configs/icedtea-bin-7 b/tests/testsuite/test_env2/usr/share/java-config-2/vm/icedtea-bin-7
index 01e4027..01e4027 100644
--- a/tests/testsuite2/vm_configs/icedtea-bin-7
+++ b/tests/testsuite/test_env2/usr/share/java-config-2/vm/icedtea-bin-7
diff --git a/tests/testsuite2/packages/jsch/package.env b/tests/testsuite/test_env2/usr/share/jsch/package.env
index 6cf0193..6cf0193 100644
--- a/tests/testsuite2/packages/jsch/package.env
+++ b/tests/testsuite/test_env2/usr/share/jsch/package.env
diff --git a/tests/testsuite2/packages/jzlib/package.env b/tests/testsuite/test_env2/usr/share/jzlib/package.env
index fb1d810..fb1d810 100644
--- a/tests/testsuite2/packages/jzlib/package.env
+++ b/tests/testsuite/test_env2/usr/share/jzlib/package.env
diff --git a/tests/testsuite2/packages/xerces-2/package.env b/tests/testsuite/test_env2/usr/share/xerces-2/package.env
index 06f637c..06f637c 100644
--- a/tests/testsuite2/packages/xerces-2/package.env
+++ b/tests/testsuite/test_env2/usr/share/xerces-2/package.env
diff --git a/tests/testsuite2/packages/xml-commons-external-1.4/package.env b/tests/testsuite/test_env2/usr/share/xml-commons-external-1.4/package.env
index 2b8d8e4..2b8d8e4 100644
--- a/tests/testsuite2/packages/xml-commons-external-1.4/package.env
+++ b/tests/testsuite/test_env2/usr/share/xml-commons-external-1.4/package.env
diff --git a/tests/testsuite2/packages/xml-commons-resolver/package.env b/tests/testsuite/test_env2/usr/share/xml-commons-resolver/package.env
index 6caae64..6caae64 100644
--- a/tests/testsuite2/packages/xml-commons-resolver/package.env
+++ b/tests/testsuite/test_env2/usr/share/xml-commons-resolver/package.env
diff --git a/tests/testsuite2/__init__.py b/tests/testsuite2/__init__.py
deleted file mode 100644
index cd19d07..0000000
--- a/tests/testsuite2/__init__.py
+++ /dev/null
@@ -1,10 +0,0 @@
-__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: