<?xml version="1.0" encoding="UTF-8" standalone="no" ?>
<!DOCTYPE testmodule SYSTEM "testmodule.dtd" [
<!ENTITY gWait "10000" > 
<!ENTITY gTesterNode "0xFA" > 
<!ENTITY CAPLFilePaths "TSL_EAS.can" > ]>
<testmodule title="J1939 Test Module" version="1.0">

  <description>The general J1939 tests, which check especially the protocol</description>

  <testgroup title="J1939 protocol specific tests">
    <description>Check for the complete testgroup that BAM TP is correct transmitted.</description>
    <constraints>
      <j1939_BAM_violation>
        <j1939_node name="EAS"/>
      </j1939_BAM_violation>
    </constraints>
    <testcase ident="1.1" title="Test answers to requests">
      <description>This tests sends requests for PGs and checks, if there is a response to the request.</description>
      <j1939_request_response timeout="1250" title="Request Response Pattern">
        <j1939_pg id="PROB_2_EAS" receiveNode="0xFA" sendNode="0x3D"/>
        <j1939_pg id="PROB_1_EAS" receiveNode="0xFA" sendNode="0x3d"/>
        <j1939_pg id="DM1_EAS" dlc="*" receiveNode="0xFA" sendNode="0x3D"/>
        <j1939_pg id="DM2_EAS" dlc="*" receiveNode="0xFA" sendNode="0x3D"/>
      </j1939_request_response>
    </testcase>
    <testcase ident="1.2" title="Check cycle time violation">
      <description>The test checks, if the cycle time for the tested PGs is in range</description>
      <constraints>
        <j1939_cycletime_rel_violation max="1.05" min="0.95">
          <j1939_pg id="PROB_1_EAS"/>
        </j1939_cycletime_rel_violation>
        <j1939_cycletime_rel_violation max="1.05" min="0.95">
          <j1939_pg id="PROB_2_EAS"/>
        </j1939_cycletime_rel_violation>
      </constraints>
      <untilend title="Wait 10000" wait="10000"/>
    </testcase>
    <testcase ident="1.3" title="Check ACL behaviour">
      <j1939_conflict_ACL title="Address Claim conflict Pattern">
        <j1939_node name="EAS"/>
      </j1939_conflict_ACL>
    </testcase>
    <testcase ident="1.4" title="Check request for ACL">
      <j1939_request_ACL title="Request Address Claim Pattern">
        <j1939_node name="EAS"/>
        <j1939_node name="EMS"/>
      </j1939_request_ACL>
    </testcase>
  </testgroup>

  <testgroup title="Functionality tests">
    <capltestcase name="CheckReactionOfEmptyFluidTank" title="Check reaction of empty fluid tank"/>
    <capltestcase name="CheckFluidTankLevel_RangeViolation" title="Check fluid tank level range violation"/>
    <capltestcase name="CheckStopSendingDTC" title="Check stop sending DTC"/>
  </testgroup>

</testmodule>
