Move the functions out of the ready function. this makes the JS tests pass.
svn path=/plone.app.discussion/trunk/; revision=39151
This commit is contained in:
@@ -4,41 +4,41 @@
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"
|
||||
dir="ltr" id="html">
|
||||
<head>
|
||||
<meta name="generator" content=
|
||||
"HTML Tidy, see www.w3.org" />
|
||||
<meta http-equiv="Content-Type" content=
|
||||
"text/html; charset=utf-8" />
|
||||
<title>plone.app.discussion comments Test Suite</title>
|
||||
|
||||
<title>plone.app.discussion comments Test Suite</title>
|
||||
<!-- QUnit -->
|
||||
<link rel="stylesheet" href="../qunit/qunit.css" type=
|
||||
"text/css" media="screen" />
|
||||
<script type="text/javascript" src="../qunit/qunit.js">
|
||||
</script>
|
||||
<!-- Scripts -->
|
||||
<script type="text/javascript" src="jquery.js">
|
||||
</script>
|
||||
<script type="text/javascript" src=
|
||||
"../../browser/javascripts/comments.js">
|
||||
</script>
|
||||
<!-- Tests -->
|
||||
<script type="text/javascript" src="test_comments.js">
|
||||
</script>
|
||||
</head>
|
||||
<!-- pad js -->
|
||||
<script type="text/javascript" src="../../browser/javascripts/comments.js">
|
||||
</script>
|
||||
|
||||
<!-- QUnit -->
|
||||
<link rel="stylesheet" href="../qunit/qunit.css" type=
|
||||
"text/css" media="screen" />
|
||||
<script type="text/javascript" src="../qunit/qunit.js">
|
||||
</script>
|
||||
<!-- Scripts -->
|
||||
<script type="text/javascript" src="jquery.js">
|
||||
</script>
|
||||
|
||||
<body>
|
||||
<h1 id="qunit-header">plone.app.discussion comments Test
|
||||
Suite</h1>
|
||||
<!-- Tests -->
|
||||
<script type="text/javascript" src="test_comments.js">
|
||||
</script>
|
||||
|
||||
<h2 id="qunit-banner"></h2>
|
||||
</head>
|
||||
|
||||
<div id="qunit-testrunner-toolbar">
|
||||
</div>
|
||||
<body>
|
||||
<h1 id="qunit-header">plone.app.discussion comments Test
|
||||
Suite</h1>
|
||||
|
||||
<h2 id="qunit-userAgent"></h2>
|
||||
<h2 id="qunit-banner"></h2>
|
||||
|
||||
<div id="qunit-testrunner-toolbar">
|
||||
</div>
|
||||
|
||||
<h2 id="qunit-userAgent"></h2>
|
||||
|
||||
<ol id="qunit-tests">
|
||||
</ol>
|
||||
</body>
|
||||
|
||||
<ol id="qunit-tests">
|
||||
</ol>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
|
||||
$(document).ready(function () {
|
||||
|
||||
|
||||
module("comments", {
|
||||
setup: function () {
|
||||
@@ -96,5 +98,9 @@ test("Clear all form values from a form.", function() {
|
||||
var text = comment_div.find("input[name='form.widgets.text']");
|
||||
equals(author.val(), "", "The author form value should be empty");
|
||||
equals(text.text(), "", "The text form value should be empty");
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user