test242.txml 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. <?xml version="1.0"?>
  2. <!-- test that markup specified by 'src' and by <content> is treated the same way. That means that
  3. either we get done.invoke in both cases or in neither case (in which case we timeout) -->
  4. <scxml initial="s0" version="1.0" conf:datamodel="" xmlns="http://www.w3.org/2005/07/scxml" xmlns:conf="http://www.w3.org/2005/scxml-conformance">
  5. <state id="s0" >
  6. <onentry>
  7. <send event="timeout1" delay="1s"/>
  8. </onentry>
  9. <transition event="timeout" conf:targetfail=""/>
  10. <invoke type="http://www.w3.org/TR/scxml/" src="file:test242sub1.scxml"/>
  11. <transition event="done.invoke" target="s02"/>
  12. <transition event="timeout1" target="s03"/>
  13. </state>
  14. <state id="s02">
  15. <onentry>
  16. <send event="timeout2" delay="1s"/>
  17. </onentry>
  18. <invoke type="http://www.w3.org/TR/scxml/">
  19. <!-- identical to test242sub1.scxml. -->
  20. <content>
  21. <scxml version="1.0" initial="subFinal1" conf:datamodel="" xmlns="http://www.w3.org/2005/07/scxml" xmlns:conf="http://www.w3.org/2005/scxml-conformance">
  22. <final id="subFinal1"/>
  23. </scxml>
  24. </content>
  25. </invoke>
  26. <!-- we got done.invoke last time, so we need it this time too -->
  27. <transition event="done.invoke" conf:targetpass=""/>
  28. <transition event="timeout2" conf:targetfail=""/>
  29. </state>
  30. <state id="s03">
  31. <onentry>
  32. <send event="timeout3" delay="1s"/>
  33. </onentry>
  34. <invoke type="http://www.w3.org/TR/scxml/">
  35. <!-- identical to test242sub1.scxml. -->
  36. <content>
  37. <scxml version="1.0" initial="subFinal2" conf:datamodel="" xmlns="http://www.w3.org/2005/07/scxml" xmlns:conf="http://www.w3.org/2005/scxml-conformance">
  38. <final id="subFinal2"/>
  39. </scxml>
  40. </content>
  41. </invoke>
  42. <!-- we got timeout last time, so we need it this time too -->
  43. <transition event="timeout3" conf:targetpass=""/>
  44. <transition event="done.invoke" conf:targetfail=""/>
  45. </state>
  46. <conf:pass/>
  47. <conf:fail/>
  48. </scxml>