summaryrefslogtreecommitdiffstats
path: root/test/w3c/ecma/test207.scxml
diff options
context:
space:
mode:
Diffstat (limited to 'test/w3c/ecma/test207.scxml')
-rw-r--r--test/w3c/ecma/test207.scxml91
1 files changed, 45 insertions, 46 deletions
diff --git a/test/w3c/ecma/test207.scxml b/test/w3c/ecma/test207.scxml
index fe30bf1..5b89697 100644
--- a/test/w3c/ecma/test207.scxml
+++ b/test/w3c/ecma/test207.scxml
@@ -1,56 +1,55 @@
-<?xml version="1.0" encoding="UTF-8"?><!-- we test that that we can't cancel an event in another session. We invoke a child process. It notifies
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- we test that that we can't cancel an event in another session. We invoke a child process. It notifies
us when it has generated a delayed event with sendid foo. We try to cancel foo. The child process sends us event
event success if the event is not cancelled, event fail otherwise. This doesn't test that there is absolutely no way to cancel an event
-raised in another session, but the spec doesn't define any way to refer to an event in another process --><scxml xmlns="http://www.w3.org/2005/07/scxml" xmlns:conf="http://www.w3.org/2005/scxml-conformance" initial="s0" version="1.0" datamodel="ecmascript">
-
-
-<state id="s0" initial="s01">
- <onentry>
- <send event="timeout" delayexpr="'100ms'"/>
+raised in another session, but the spec doesn't define any way to refer to an event in another process -->
+<scxml xmlns="http://www.w3.org/2005/07/scxml" xmlns:conf="http://www.w3.org/2005/scxml-conformance" initial="s0" version="1.0" datamodel="ecmascript">
+ <state id="s0" initial="s01">
+ <onentry>
+ <send event="timeout" delayexpr="'100ms'"/>
</onentry>
- <invoke type="scxml">
- <content>
- <!-- when invoked, we raise a delayed event1 with sendid 'foo' and notify our parent. Then we wait.
+ <invoke type="scxml">
+ <content>
+ <!-- when invoked, we raise a delayed event1 with sendid 'foo' and notify our parent. Then we wait.
If event1 occurs, the parent hasn't succeeded in canceling it and we return pass. If event2 occurs
it means event1 was canceled (because event2 is delayed longer than event1) and we return 'fail'. -->
-
-
- <scxml initial="sub0" version="1.0" datamodel="ecmascript">
- <state id="sub0">
+ <scxml initial="sub0" version="1.0" datamodel="ecmascript">
+ <state id="sub0">
<onentry>
- <send event="event1" id="foo" delayexpr="'50ms'"/>
+ <send event="event1" id="foo" delayexpr="'50ms'"/>
<send event="event2" delayexpr="'75ms'"/>
<send target="#_parent" event="childToParent"/>
- </onentry>
-
- <transition event="event1" target="subFinal">
- <send target="#_parent" event="pass"/>
- </transition>
- <transition event="*" target="subFinal">
- <send target="#_parent" event="fail"/>
- </transition>
-
- </state>
- <final id="subFinal"/>
- </scxml>
- </content>
+ </onentry>
+ <transition event="event1" target="subFinal">
+ <send target="#_parent" event="pass"/>
+ </transition>
+ <transition event="*" target="subFinal">
+ <send target="#_parent" event="fail"/>
+ </transition>
+ </state>
+ <final id="subFinal"/>
+ </scxml>
+ </content>
</invoke>
-
- <state id="s01">
- <transition event="childToParent" target="s02">
- <cancel sendid="foo"/>
+ <state id="s01">
+ <transition event="childToParent" target="s02">
+ <cancel sendid="foo"/>
</transition>
- </state>
-
- <state id="s02">
- <transition event="pass" target="pass"/>
- <transition event="fail" target="fail"/>
- <transition event="timeout" target="fail"/>
- </state>
-
-</state>
-
-<final id="pass"><onentry><log label="Outcome" expr="'pass'"/></onentry></final>
-<final id="fail"><onentry><log label="Outcome" expr="'fail'"/></onentry></final>
-
-</scxml> \ No newline at end of file
+ </state>
+ <state id="s02">
+ <transition event="pass" target="pass"/>
+ <transition event="fail" target="fail"/>
+ <transition event="timeout" target="fail"/>
+ </state>
+ </state>
+ <final id="pass">
+ <onentry>
+ <log label="Outcome" expr="'pass'"/>
+ </onentry>
+ </final>
+ <final id="fail">
+ <onentry>
+ <log label="Outcome" expr="'fail'"/>
+ </onentry>
+ </final>
+</scxml>