Bug 7397 - yang-system-test could fail if zero yang files were found
[yangtools.git] / yang / yang-system-test / src / main / java / org / opendaylight / yangtools / yang / parser / system / test / SystemTestUtils.java
index e35a6e899baee300615c319def7769a59b228fb0..a3d3d656041cddeafc28736306f30f1b42829a93 100644 (file)
@@ -68,6 +68,7 @@ class SystemTestUtils {
 
     static SchemaContext parseYangSources(final StatementStreamSource[] testSources,
             final StatementStreamSource[] libSources, final Set<QName> supportedFeatures) throws ReactorException {
+        Preconditions.checkArgument(testSources != null && testSources.length > 0, "No yang sources");
 
         final CrossSourceStatementReactor.BuildAction reactor = YangInferencePipeline.RFC6020_REACTOR
                 .newBuild(supportedFeatures);