Skip to content

Commit

Permalink
fixup! Fix Ignored RootNS
Browse files Browse the repository at this point in the history
- add doc comment
- update test names

DAFFODIL-2947
  • Loading branch information
olabusayoT committed Nov 7, 2024
1 parent a706c0c commit aa7ba35
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -362,6 +362,11 @@ final class SchemaSet private (
if (possibleRoots.length == 1) {
possibleRoots.head
} else {
// we're here because it's ambiguous what root element to return, and
// no namespace URI was provided. So we assume not specifying a namespace
// URI may mean the intention was to choose the root that it is in No Namespace.
// If there is no such, then the diagnostic will encourage user to specify
// the namespace explicitly.
val qn = RefQName(None, rootElementName, NoNamespace)
findRootElement(qn)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -609,7 +609,7 @@ abc # a comment
@Test def test_apos_test2(): Unit = { runner.runOneTest("apos_test2") }

// DFDL-2947
@Test def test_multipleRootCandidates1(): Unit = {
@Test def test_rootNSSpecifiesNoNamespaceRoot(): Unit = {
val tdmlTestSuite =
<tdml:testSuite suiteName="theSuiteName" xmlns:ex={example} xmlns:tdml={tdml} xmlns:dfdl={
dfdl
Expand All @@ -628,7 +628,7 @@ abc # a comment
runner.runOneTest("test1")
}

@Test def test_multipleRootCandidates2(): Unit = {
@Test def test_rootNSSpecifiesNamespaceRoot(): Unit = {
val tdmlTestSuite =
<tdml:testSuite suiteName="theSuiteName" xmlns:ex={example} xmlns:tdml={tdml} xmlns:dfdl={
dfdl
Expand Down

0 comments on commit aa7ba35

Please sign in to comment.