Author: jvloothuis
Date: Fri May  2 10:20:09 2008
New Revision: 54314

Modified:
   kukit/kss.core/trunk/kss/core/plugins/core/demo/configure.zcml
   kukit/kss.core/trunk/kss/core/plugins/core/demo/demoview.py
   kukit/kss.core/trunk/kss/core/plugins/core/demo/protocol.kss
   kukit/kss.core/trunk/kss/core/plugins/core/demo/protocol.pt
   kukit/kss.core/trunk/kss/core/plugins/core/demo/selenium_tests/protocol.html
Log:

Added tests for named entities to make sure both kss.core and kss.base
work with these properly (especially in IE).


Modified: kukit/kss.core/trunk/kss/core/plugins/core/demo/configure.zcml
==============================================================================
--- kukit/kss.core/trunk/kss/core/plugins/core/demo/configure.zcml      
(original)
+++ kukit/kss.core/trunk/kss/core/plugins/core/demo/configure.zcml      Fri May 
 2 10:20:09 2008
@@ -545,5 +545,21 @@
     permission="zope.View"
     />
 
+  <browser:page
+    for="kss.demo.interfaces.ISimpleContent"
+    class=".demoview.KSSDemoView"
+    attribute="protocolAgrave"
+    name="protocolAgrave"
+    permission="zope.View"
+    />
+
+  <browser:page
+    for="kss.demo.interfaces.ISimpleContent"
+    class=".demoview.KSSDemoView"
+    attribute="protocolEacute"
+    name="protocolEacute"
+    permission="zope.View"
+    />
+
 </configure>
 

Modified: kukit/kss.core/trunk/kss/core/plugins/core/demo/demoview.py
==============================================================================
--- kukit/kss.core/trunk/kss/core/plugins/core/demo/demoview.py (original)
+++ kukit/kss.core/trunk/kss/core/plugins/core/demo/demoview.py Fri May  2 
10:20:09 2008
@@ -266,3 +266,12 @@
             '#character-attr-output', 'title', 'before ]]> after')
         return self.render()
     
+    def protocolAgrave(self):
+        self.getCommandSet('core').replaceInnerHTML(
+            '#named-entity-output', '&agrave')
+        return self.render()
+    
+    def protocolEacute(self):
+        self.getCommandSet('core').replaceInnerHTML(
+            '#named-entity-output', '&eacute')
+        return self.render()

Modified: kukit/kss.core/trunk/kss/core/plugins/core/demo/protocol.kss
==============================================================================
--- kukit/kss.core/trunk/kss/core/plugins/core/demo/protocol.kss        
(original)
+++ kukit/kss.core/trunk/kss/core/plugins/core/demo/protocol.kss        Fri May 
 2 10:20:09 2008
@@ -56,4 +56,14 @@
 #attr-endcdata:click {
     evt-click-preventdefault: true;
     action-server: protocolAttributeENDCDATA;
+}
+
+#agrave:click {
+    evt-click-preventdefault: true;
+    action-server: protocolAgrave;
+}
+
+#eacute:click {
+    evt-click-preventdefault: true;
+    action-server: protocolEacute;
 }
\ No newline at end of file

Modified: kukit/kss.core/trunk/kss/core/plugins/core/demo/protocol.pt
==============================================================================
--- kukit/kss.core/trunk/kss/core/plugins/core/demo/protocol.pt (original)
+++ kukit/kss.core/trunk/kss/core/plugins/core/demo/protocol.pt Fri May  2 
10:20:09 2008
@@ -86,6 +86,20 @@
     </ol>
 
     <a href="#" id="character-attr-output">Link which get a title attribute</a>
+
+    <h2>Named entities</h2> 
+    <p>Named entities should work. The next example demonstrates that
+    the server can send data with named entities.</p>
+
+    <ol>
+      <li><a href="#" id="agrave">Command with an &agrave;</a></li>
+      <li><a href="#" id="eacute">Command with a &eacute;</a></li>
+    </ol>
+
+    <div id="named-entity-output">
+      test data will appear here
+    </div>
+    
     
   </body>
 </html>

Modified: 
kukit/kss.core/trunk/kss/core/plugins/core/demo/selenium_tests/protocol.html
==============================================================================
--- 
kukit/kss.core/trunk/kss/core/plugins/core/demo/selenium_tests/protocol.html    
    (original)
+++ 
kukit/kss.core/trunk/kss/core/plugins/core/demo/selenium_tests/protocol.html    
    Fri May  2 10:20:09 2008
@@ -163,6 +163,26 @@
        <td>[EMAIL PROTECTED]</td>
        <td>before ]]&gt; after</td>
 </tr>
+<tr>
+       <td>click</td>
+       <td>agrave</td>
+       <td></td>
+</tr>
+<tr>
+       <td>waitForText</td>
+       <td>named-entity-output</td>
+       <td>&agrave;</td>
+</tr>
+<tr>
+       <td>click</td>
+       <td>eacute</td>
+       <td></td>
+</tr>
+<tr>
+       <td>waitForText</td>
+       <td>named-entity-output</td>
+       <td>&eacute;</td>
+</tr>
 
 </tbody></table>
 </body>
_______________________________________________
Kukit-checkins mailing list
[email protected]
http://codespeak.net/mailman/listinfo/kukit-checkins

Reply via email to