RecordFlux
RecordFlux copied to clipboard
Coverage of specifications cannot reach 100%
With the current implementation of the validator, it is not possible to reach 100% coverage for some specifications. There are 3 cases that lead to this problem:
- A specification imports another specification but does not define a refinement to messages of the imported specification. For example, the
arp.rflx
specification importsipv4.rflx
but only uses field types ofipv4.rflx
, it does not define a refinement ARP -> IPv4 (of cause not). The output of the validation is shown below. - A specification imports another specification and defines a refinement to only one message of the imported specification (if multiple messages are defined in the imported specification).
- A specification contains completely separate messages. Cf. #833
- (and combinations of the 3 cases)
Discussed suggestions so far:
- Compute the coverage per-message not per-specification file. As a downside, this could lead to forgotten messages.
- Only compute coverage of the PDU specification, do not include refinements. (i.e. when validating
ARP::Packet_IPv4
only get coverage ofarp.rflx
). This would require some logic to include refinement messages that are an integral part of the PDU, as e.g. IPv4Options to IPv4. This would also make getting test data easier, as one would not need to search for specific combinations of PDU/SDU messages.
--------------------------------------------------------------------------------
RecordFlux Validation Coverage Report
Directory: /home/rs/Dev/RecordFlux-specifications
--------------------------------------------------------------------------------
File Links Used Coverage
ipv4.rflx 27 0 0.00%
ethernet.rflx 12 0 0.00%
arp.rflx 10 10 100.00%
--------------------------------------------------------------------------------
TOTAL 49 10 20.41%
--------------------------------------------------------------------------------
Related to #814