Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TRUNK-5399 Add and fix config xml dtd files 1-0.1.5 #2666

Merged
merged 1 commit into from
May 12, 2018

Conversation

teleivo
Copy link
Member

@teleivo teleivo commented May 12, 2018

Description of what I changed

  • add the DTD files for the config.xml in versions 1.0-1.5 to the
    resources of org/openmrs/module/dtd so they are under version control,
    can easily be found, edited and uploaded back to resource.openmrs.org
  • add elements that were not declared and thus made the DTDs invalid and
    not useful for devs writing their config.xml

dwr

  • add missing elements judging from legacyui dwr element in config.xml
  • create (param, include*) always has a param and can have 0-N include's
    param and include are empty elements with required attributes
  • convert has one optional param child

mappingFiles

  • fix the mappingFiles quantifier since it should only occur Zero or One
    time thus use ?. mappingFiles itself can have multiple whitespace
    separated filenames

require_modules

  • be more strict on require_modules which should have 1-N require_module
    instead of 0-N, because why declare it if you dont require any module

aware_of_modules

  • add aware_of_modules element to version 1.4, which was missing in
    the file uploaded to resources.openmrs.org and this also has to have 1-N
    aware_of_module if added

filter-mapping

  • filter-mapping added in 1.2 defines that one of the following
    url-pattern or servlet-name elements must be included thus the pattern
    (url-pattern | servlet-name)

Issue I worked on

see https://issues.openmrs.org/browse/TRUNK-5399

* add the DTD files for the config.xml in versions 1.0-1.5 to the
resources of org/openmrs/module/dtd so they are under version control,
can easily be found, edited and uploaded back to resource.openmrs.org
* add elements that were not declared and thus made the DTDs invalid and
not useful for devs writing their config.xml

dwr
* add missing elements judging from legacyui dwr element in config.xml
* create (param, include*) always has a param and can have 0-N include's
param and include are empty elements with required attributes
* convert has one optional param child

mappingFiles
* fix the mappingFiles quantifier since it should only occur Zero or One
time thus use `?`. mappingFiles itself can have multiple whitespace
separated filenames

require_modules
* be more strict on `require_modules` which should have 1-N `require_module`
instead of 0-N, because why declare it if you dont require any module

aware_of_modules
* add `aware_of_modules` element to version 1.4, which was missing in
the file uploaded to resources.openmrs.org and this also has to have 1-N
`aware_of_module` if added

filter-mapping
* filter-mapping added in 1.2 defines that one of the following
url-pattern or servlet-name elements must be included thus the pattern
(url-pattern | servlet-name)
@coveralls
Copy link

Coverage Status

Coverage increased (+0.003%) to 59.012% when pulling 2bf2372 on teleivo:TRUNK-5399 into b800f2d on openmrs:master.

@teleivo teleivo merged commit 329dff3 into openmrs:master May 12, 2018
@teleivo teleivo deleted the TRUNK-5399 branch May 12, 2018 06:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants