Univention Bugzilla – Attachment 5497 Details for
Bug 32554
ucs_registerUDMModule library function
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
fix some of the tests
1.patch (text/plain), 5.74 KB, created by
Arvid Requate
on 2013-10-07 21:49 CEST
(
hide
)
Description:
fix some of the tests
Filename:
MIME Type:
Creator:
Arvid Requate
Created:
2013-10-07 21:49 CEST
Size:
5.74 KB
patch
obsolete
>Index: univention/testing/udm_extensions.py >=================================================================== >--- univention/testing/udm_extensions.py (Revision 44858) >+++ univention/testing/udm_extensions.py (Arbeitskopie) >@@ -222,7 +222,7 @@ > if not app_id: > app_id = '' > else: >- app_id = 'UNIVENTION_APP_IDENTIFIER="%s"' % app_id >+ app_id = 'export UNIVENTION_APP_IDENTIFIER="%s"' % app_id > if not version_start: > version_start = '' > else: >@@ -269,7 +269,7 @@ > if not app_id: > app_id = '' > else: >- app_id = 'UNIVENTION_APP_IDENTIFIER="%s"' % app_id >+ app_id = 'export UNIVENTION_APP_IDENTIFIER="%s"' % app_id > if not version_start: > version_start = '' > else: >Index: tests/72_udm-extensions/10_update_extension_via_package >=================================================================== >--- tests/72_udm-extensions/10_update_extension_via_package (Revision 44858) >+++ tests/72_udm-extensions/10_update_extension_via_package (Arbeitskopie) >@@ -31,8 +31,9 @@ > version_start = random_ucs_version(max_major=2) > version_end = random_ucs_version(min_major=5) > >- # create special extension name >- extension_identifier = '%s_%s' % (extension_name, package_version.replace('.','_')) >+ # extension name is the one finally appearing in the "name" attribute of the UDM module >+ # extension_identifier = '%s_%s' % (extension_name, package_version.replace('.','_')) >+ extension_identifier = '%s' % (extension_name,) > extension_buffer = get_extension_buffer(extension_type, extension_identifier) > joinscript_buffer = get_join_script_buffer(extension_type, > '/usr/share/%s/%s' % (package_name, extension_filename), >Index: tests/72_udm-extensions/12_update_extension_via_other_packagename >=================================================================== >--- tests/72_udm-extensions/12_update_extension_via_other_packagename (Revision 44858) >+++ tests/72_udm-extensions/12_update_extension_via_other_packagename (Arbeitskopie) >@@ -31,8 +31,9 @@ > version_start = random_ucs_version(max_major=2) > version_end = random_ucs_version(min_major=5) > >- # create special extension name >- extension_identifier = '%s_%s' % (extension_name, package_version.replace('.','_')) >+ # extension name is the one finally appearing in the "name" attribute of the UDM module >+ # extension_identifier = '%s_%s' % (extension_name, package_version.replace('.','_')) >+ extension_identifier = '%s' % (extension_name,) > extension_buffer = get_extension_buffer(extension_type, extension_identifier) > joinscript_buffer = get_join_script_buffer(extension_type, > '/usr/share/%s/%s' % (package_name, extension_filename), >Index: tests/72_udm-extensions/41_test_udm_module >=================================================================== >--- tests/72_udm-extensions/41_test_udm_module (Revision 44858) >+++ tests/72_udm-extensions/41_test_udm_module (Arbeitskopie) >@@ -8,7 +8,7 @@ > > from univention.config_registry import ConfigRegistry > import univention.testing.udm as udm_test >-from univention.testing.utils import verify_ldap_object, wait_for_replication_and_postrun, fail >+from univention.testing.utils import verify_ldap_object, wait_for_replication, fail > from univention.testing.strings import random_name, random_version, random_ucs_version > from univention.testing.udm_extensions import * > import subprocess >@@ -43,7 +43,7 @@ > ucsversionend = version_end, > active = 'FALSE') > >- wait_for_replication_and_postrun() >+ wait_for_replication() > udm.stop_cli_server() > > verify_ldap_object(dn, { >@@ -57,14 +57,14 @@ > > }) > >- output = subprocess.Popen(['udm', 'modules'], stdout=subprocess.PIPE).communicate() >+ output, stderr = subprocess.Popen(['udm', 'modules'], stdout=subprocess.PIPE).communicate() > if not extension_name in output: > fail('ERROR: udm cli server has not been reloaded yet or module registration failed') > > extension_dn = udm.create_object(extension_name, position=ucr.get('ldap/base'), name=object_name) > udm.remove_object(extension_name, dn=extension_dn) > >- wait_for_replication_and_postrun() >+ wait_for_replication() > udm.stop_cli_server() > > with udm_test.UCSTestUDM() as udm: >Index: tests/72_udm-extensions/11_update_extension_via_package_expected_fail >=================================================================== >--- tests/72_udm-extensions/11_update_extension_via_package_expected_fail (Revision 44858) >+++ tests/72_udm-extensions/11_update_extension_via_package_expected_fail (Arbeitskopie) >@@ -27,8 +27,9 @@ > packages = [] > try: > for package_version in (package_version_HIGH, package_version_LOW): >- # create special extension name >- extension_identifier = '%s_%s' % (extension_name, package_version.replace('.','_')) >+ # extension name is the one finally appearing in the "name" attribute of the UDM module >+ # extension_identifier = '%s_%s' % (extension_name, package_version.replace('.','_')) >+ extension_identifier = '%s' % (extension_name,) > extension_buffer = get_extension_buffer(extension_type, extension_identifier) > joinscript_buffer = get_join_script_buffer(extension_type, > '/usr/share/%s/%s' % (package_name, extension_filename), >@@ -58,7 +59,7 @@ > content = open(get_absolute_extension_filename(extension_type, extension_filename)).read() > if package_version == package_version_HIGH and not extension_identifier in content: > fail('ERROR: UDM extension of package %d has not been written to disk (%s)' % (len(packages), extension_filename,)) >- if package_version == package_version_LOW and not extension_identifier in content: >+ if package_version == package_version_LOW and extension_identifier in content: > fail('ERROR: the extension update has been performed but should not (old version=%s ; new version=%s)' % (package_version_HIGH, package_version_LOW)) > > finally:
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
Actions:
View
|
Diff
Attachments on
bug 32554
:
5497
|
5505
|
5536