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

  $Author: richard $

  $Revision: 1.4 $

  $Log: 2,v $
  Revision 1.4  2002/03/16 13:59:57  richard
  rewrite test

  Revision 1.3  2001/10/30 16:22:23  gb
  Modified all the test files in the wml2 directory such that it puts the <?xml?> declaration back at the top of the file, before the comment.

  Revision 1.2  2001/10/08 21:56:12  gb
  Added the standard header of Author, Revision and Log at the top of each template file.


-->
<test id="wml2/uabehaviour/attribexplang/wmlvariable/eventparam/2" 
	class="B" scope="wml2" testtype="application" type="manual" 
	source="wml2#5.5.1.6" device="both">
  <assertion>When an event defines no parameters and an expression is used 
  to set a variable using the '$1' syntax, the value of the expression 
  must be empty.
  </assertion>
  <notes>Create a card that attempts to set a variable using the 
  '$&lt;number&gt;' syntax, within the enterforward event handler. The 
  card could then be set to navigate to a script that checks that the 
  variable is empty.
  </notes>
  <specnote>Untestable as there are no means to check the value of an
  event parameter reference inside an WML:ONEVENT element.
  </specnote>
  <results>
    <result>
      <name>submit</name>
      <value>yes</value>
    </result>
  </results>
  <method>
<![CDATA[
  <wml:card newcontext="true" id="main" title="main">
    <wml:onevent type="enterforward">
      <wml:go href="#card2" />
    </wml:onevent>
    <p wml:mode="wrap">Was the value of the $$x variable an empty string?
    <br />
[[yesno]]
    </p>
  </wml:card>
  <wml:card id="card2" title="card2">
    <wml:onevent type="enterforward">
      <wml:refresh>
        <wml:setvar name="x" value="$1" />
      </wml:refresh>
    </wml:onevent>
      <wml:do role="back">
        <wml:prev />
      </wml:do>
    <p>
      The variable $$x = $x
    </p>
    <p>
      Now go back
    </p>
  </wml:card>
]]>
  </method>
</test>
