Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Adding JavaScript Contribution

  • Loading branch information...
commit 5061b24b9ea7daf78beb9f3c12fc0c3dbcd6cc1c 1 parent dcbbb9f
@jeanlaurent jeanlaurent authored
View
3  starting_points/javascript/README.md
@@ -0,0 +1,3 @@
+## Simple JavaScript Setup using QUnit
+
+to run testsuites just open coderetreat.html in a capable browser.
View
21 starting_points/javascript/coderetreat.html
@@ -0,0 +1,21 @@
+<!DOCTYPE html>
+<html>
+<head>
+ <title>coderetreat Test Suite</title>
+ <script src="http://code.jquery.com/jquery-latest.js"></script>
+ <link rel="stylesheet" href="http://code.jquery.com/qunit/git/qunit.css" type="text/css" media="screen"/>
+ <script type="text/javascript" src="http://code.jquery.com/qunit/git/qunit.js"></script>
+ <!-- Your project file goes here -->
+ <script type="text/javascript" src="coderetreat.js"></script>
+ <!-- Your tests file goes here -->
+ <script type="text/javascript" src="coderetreatTest.js"></script>
+</head>
+<body>
+ <h1 id="qunit-header">coderetreat</h1>
+ <h2 id="qunit-banner"></h2>
+ <div id="qunit-testrunner-toolbar"></div>
+ <h2 id="qunit-userAgent"></h2>
+ <ol id="qunit-tests"></ol>
+ <div id="qunit-fixture">test markup, will be hidden</div>
+</body>
+</html>
View
3  starting_points/javascript/coderetreat.js
@@ -0,0 +1,3 @@
+function foo() {
+ return "qix";
+}
View
4 starting_points/javascript/coderetreatTest.js
@@ -0,0 +1,4 @@
+test('is foo "bar" ?', function() {
+ equals(foo(), "bar");
+})
+
Please sign in to comment.
Something went wrong with that request. Please try again.