-
Notifications
You must be signed in to change notification settings - Fork 15
Description
Prerequisites
- I have written a descriptive issue title
- I have verified that I am running the latest version of the ReqIFSharp
- I have searched open and closed issues to ensure it has not already been reported
Description
ReqIF 'TOOL-EXTENSIONS' are not loaded when the rest of the ReqIF file is deserialized.
Some brute force debugging of commenting out chunks of ReqIF.cs showed that commenting out the following lines in the ReqIF.cs file allows Tool-Extensions to load:
https://github.com/RHEAGROUP/reqifsharp/blob/2116a7a3e2ba9e4aaa8e57aa012a3d70eb6d3fa0/ReqIFSharp/ReqIF.cs#L64-L75
Some further debugging into ReqIFContent.cs lead me to the ReadXml function:
https://github.com/RHEAGROUP/reqifsharp/blob/2116a7a3e2ba9e4aaa8e57aa012a3d70eb6d3fa0/ReqIFSharp/ReqIFContent.cs#L139-L141
The while loop appears to be iterating over all remaining XML elements in the file, going outside the scope of the CORE-CONTENT and REQ-IF-CONTENT elements.
Steps to Reproduce
Reference ReqIF file:
ProR_Traceability-Template-v1.0.reqif.zip
Following Nunit test fails for the provided ReqIF file:
var path = "ProR_Traceability-Template-v1.0.reqif";
var deserializer = new ReqIFSharp.ReqIFDeserializer();
var reqif = deserializer.Deserialize(path);
Assert.That(reqif.TheHeader, Is.Not.Empty);
Assert.That(reqif.CoreContent, Is.Not.Empty);
// Note: This is the problem. This SHOULDN'T be empty, but it is.
Assert.That(reqif.ToolExtensions, Is.Not.Empty);
System Configuration
- ReqIFSharp version:
- ReqIFSharp: v2.0.0
- Other:
- Environment (Operating system, version and so on): Windows 10
- .NET Framework version: .NET Core 2.1
- Additional information: