This is an automated email from the git hooks/post-receive script.
firstyear pushed a commit to branch master
in repository 389-ds-base.
commit f78663990f821627db181834baf708ce492cf0d2
Author: William Brown <firstyear(a)redhat.com>
Date: Wed Mar 15 12:26:59 2017 +1000
Ticket 49172 - Fix test schema files
Bug Description: This issue has two points. First, is that we were not
handling conditions where schema was empty, so we got a none type back.
Second, schema handling moves in 1.3.6, to the join systemschema dir and
schemadir. We should be reflective of this in our test, which requires and
update to the defaults.inf to list the path.
Fix Description: Update defaults.inf, and the test to correctly
handle none.
https://pagure.io/389-ds-base/issue/49172
Author: wibrown
Review by: mreynolds (thanks!)
---
dirsrvtests/tests/suites/schema/test_schema.py | 4 ++++
ldap/admin/src/defaults.inf.in | 1 +
2 files changed, 5 insertions(+)
diff --git a/dirsrvtests/tests/suites/schema/test_schema.py
b/dirsrvtests/tests/suites/schema/test_schema.py
index 10838f1..23dae71 100644
--- a/dirsrvtests/tests/suites/schema/test_schema.py
+++ b/dirsrvtests/tests/suites/schema/test_schema.py
@@ -129,8 +129,12 @@ def test_schema_comparewithfiles(topology_st):
for fn in schemainst.schema.list_files():
try:
fschema = schemainst.schema.file_to_subschema(fn)
+ if fschema is None:
+ raise Exception("Empty schema file %s" % fn)
except:
log.warn("Unable to parse %s as a schema file - skipping" % fn)
+ continue
+ log.info("Parsed %s as a schema file - checking" % fn)
for oid in fschema.listall(occlass):
se = fschema.get_obj(occlass, oid)
assert se
diff --git a/ldap/admin/src/defaults.inf.in b/ldap/admin/src/defaults.inf.in
index 31dbf2f..77d27b1 100644
--- a/ldap/admin/src/defaults.inf.in
+++ b/ldap/admin/src/defaults.inf.in
@@ -36,6 +36,7 @@ run_dir = @localstatedir@/run/dirsrv
pid_file = @localstatedir(a)/run/dirsrv/slapd-{instance_name}.pid
inst_dir = @serverdir@
plugin_dir = @serverplugindir@
+system_schema_dir = @systemschemadir@
; These values can be altered in an installation of ds
user = dirsrv
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.