<?xml version="1.0" encoding="UTF-8"?>
<!--

    Licensed under European Union Public Licence (EUPL) version 1.2.

-->
<testSet xmlns="http://difi.no/xsd/vefa/validator/1.0" configuration="tc434-ubl">
	<assert>
		<scope>BR-CO-19</scope>
	</assert>
	<test>
		<assert>
			<description>Verify that if Delivery or invoice period (BG-14) is used, the Delivery period start date or the Delivery period end date shall be filled, or both.</description>
			<success>BR-CO-19</success>
		</assert>
		<Invoice
			xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
			xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
			xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2">
			<cac:InvoicePeriod>
				<cbc:StartDate>2013-06-01</cbc:StartDate>
				<cbc:EndDate>2013-06-30</cbc:EndDate>
			</cac:InvoicePeriod>

		</Invoice>
	</test>
	<test>
		<assert>
			<description>Verify that if Delivery or invoice period (BG-14) is used, the Delivery period start date or the Delivery period end date shall be filled, or both.</description>
			<success>BR-CO-19</success>
		</assert>
		<Invoice
			xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
			xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
			xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2">
			<cac:InvoicePeriod>
				<cbc:StartDate>2013-06-01</cbc:StartDate>
	<!--			<cbc:EndDate>2013-06-30</cbc:EndDate>-->
			</cac:InvoicePeriod>
			
		</Invoice>
	</test>
	<test>
		<assert>
			<description>Verify that if Delivery or invoice period (BG-14) is used, the Delivery period start date or the Delivery period end date shall be filled, or both.</description>
			<success>BR-CO-19</success>
		</assert>
		<Invoice
			xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
			xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
			xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2">
			<cac:InvoicePeriod>
<!--				<cbc:StartDate>2013-06-01</cbc:StartDate>-->
				<cbc:EndDate>2013-06-30</cbc:EndDate>
			</cac:InvoicePeriod>
			
		</Invoice>
	</test>
	<test>
		<assert>
			<description>Trigger error if Delivery or invoice period (BG-14) is used, and the Delivery period start date and the Delivery period end date is not present.</description>
			<error>BR-CO-19</error>
		</assert>
		<Invoice
			xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
			xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
			xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2">
			<cac:InvoicePeriod>
				<!--<cbc:StartDate>2013-06-01</cbc:StartDate>
				<cbc:EndDate>2013-06-30</cbc:EndDate>-->
			</cac:InvoicePeriod>
			
		</Invoice>
	</test>
	
	<test>
		<assert>
			<description>Verify that BT-8 can be informed even if there is no Invoice period defined.</description>
			<success>BR-CO-19</success>
		</assert>
		<Invoice
			xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
			xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
			xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2">
			<cac:InvoicePeriod>
				<!--<cbc:StartDate>2013-06-01</cbc:StartDate>
				<cbc:EndDate>2013-06-30</cbc:EndDate>-->
                <cbc:DescriptionCode>3</cbc:DescriptionCode>  
			</cac:InvoicePeriod>
			
		</Invoice>
	</test>

	<test>
		<assert>
			<description>Verify that BT-8 can be informed even if there is an Invoice period defined.</description>
			<success>BR-CO-19</success>
		</assert>
		<Invoice
			xmlns:cac="urn:oasis:names:specification:ubl:schema:xsd:CommonAggregateComponents-2"
			xmlns:cbc="urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2"
			xmlns="urn:oasis:names:specification:ubl:schema:xsd:Invoice-2">
			<cac:InvoicePeriod>
				<cbc:StartDate>2020-11-01</cbc:StartDate>
				<cbc:EndDate>2020-11-30</cbc:EndDate>
				<cbc:DescriptionCode>3</cbc:DescriptionCode>
			</cac:InvoicePeriod>
			
		</Invoice>
	</test>
	
	
</testSet>
