test332.txml 1.0 KB

123456789101112131415161718192021222324252627282930313233
  1. <?xml version="1.0"?>
  2. <!-- test that sendid is present in error events triggered by send errors -->
  3. <scxml version="1.0" xmlns="http://www.w3.org/2005/07/scxml" initial="s0" conf:datamodel="" name="machineName" xmlns:conf="http://www.w3.org/2005/scxml-conformance">
  4. <datamodel>
  5. <data conf:id="1"/>
  6. <data conf:id="2"/>
  7. </datamodel>
  8. <state id="s0">
  9. <onentry>
  10. <!-- this will raise an error and also store the sendid in var1 -->
  11. <send conf:illegalTarget="" event="foo" conf:idlocation="1"/>
  12. </onentry>
  13. <transition event="error" target="s1">
  14. <!-- get the sendid out of the error event -->
  15. <assign conf:location="2" conf:eventSendid=""/>
  16. </transition>
  17. <transition event="*" conf:targetfail=""/>
  18. </state>
  19. <state id="s1">
  20. <!-- make sure that the sendid in the error event matches the one generated when send executed -->
  21. <transition conf:VarEqVar="1 2" conf:targetpass=""/>
  22. <transition conf:targetfail=""/>
  23. </state>
  24. <conf:pass/>
  25. <conf:fail/>
  26. </scxml>