Fix failure source not being reported 52/100952/1
authorRobert Varga <robert.varga@pantheon.tech>
Tue, 3 May 2022 17:27:59 +0000 (19:27 +0200)
committerRobert Varga <robert.varga@pantheon.tech>
Tue, 3 May 2022 20:07:33 +0000 (22:07 +0200)
commita0c3cda5c9209e407e811c0b3d81003629eeb6dd
treeee9f028859e600d24453c8b9e983e6e107fb51ac
parentc4b8c2431ef5ef8c538a3ebe855d58c0c758c943
Fix failure source not being reported

When the parser fails with a well-known exception, extract the
SourceIdentifier of the failed YANG source.

JIRA: YANGTOOLS-1428
Change-Id: Ib40b01a977131ce1d244be5bd4e67c39e04ab626
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 6dd19d2f87b3391b95d8087a3ff025c5414fd4e9)
(cherry picked from commit fd1fcd8b28b69bc86053ff47ddefcc42d12fdcee)
parser/yang-parser-impl/src/main/java/org/opendaylight/yangtools/yang/parser/repo/AssembleSources.java
parser/yang-parser-impl/src/test/java/org/opendaylight/yangtools/yang/parser/repo/AbstractSchemaRepositoryTest.java [new file with mode: 0644]
parser/yang-parser-impl/src/test/java/org/opendaylight/yangtools/yang/parser/repo/SchemaContextFactoryDeviationsTest.java
parser/yang-parser-impl/src/test/java/org/opendaylight/yangtools/yang/parser/repo/YT1428Test.java [new file with mode: 0644]
parser/yang-parser-impl/src/test/resources/yt1428/deviate.yang [new file with mode: 0644]
parser/yang-parser-impl/src/test/resources/yt1428/orig.yang [new file with mode: 0644]