Attribute '@unitCode' is required in this context.
The @unitCode attribute is missing from ram:ChargeFreeQuantity. The test requires the attribute to be present.
The unit code specifies the unit in which the unbilled quantity is expressed. Without it, the unit of this quantity is not specified.
The unit is missing for the unbilled quantity. Add the @unitCode attribute so that the quantity is provided with its unit.
- Locate
ram:ChargeFreeQuantityin the invoice line. - Add the required
@unitCodeattribute there. - Generate the invoice again and validate it again.
Technical details
The XPath test @unitCode checks only whether the attribute is present on the current ram:ChargeFreeQuantity.
The rule applies to the @unitCode attribute of the unbilled quantity ram:ChargeFreeQuantity in an invoice line.
rule/@context)assert/@test)