couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gar...@apache.org
Subject [1/3] added sinon, updated license and notice. Added tests
Date Thu, 18 Jul 2013 14:45:19 GMT
Updated Branches:
  refs/heads/fauxton-test-framework 251a7eff7 -> c88b72a90


http://git-wip-us.apache.org/repos/asf/couchdb/blob/c88b72a9/src/fauxton/test/mocha/testUtils.js
----------------------------------------------------------------------
diff --git a/src/fauxton/test/mocha/testUtils.js b/src/fauxton/test/mocha/testUtils.js
new file mode 100644
index 0000000..08b46de
--- /dev/null
+++ b/src/fauxton/test/mocha/testUtils.js
@@ -0,0 +1,25 @@
+// Licensed under the Apache License, Version 2.0 (the "License"); you may not
+// use this file except in compliance with the License. You may obtain a copy of
+// the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
+// WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
+// License for the specific language governing permissions and limitations under
+// the License.
+
+define([
+       "chai",
+       "sinon-chai",
+],
+function(chai, sinonChai) {
+  chai.use(sinonChai);
+
+  return {
+    chai: chai,
+    assert: chai.assert
+  };
+});
+

http://git-wip-us.apache.org/repos/asf/couchdb/blob/c88b72a9/src/fauxton/test/runner.html
----------------------------------------------------------------------
diff --git a/src/fauxton/test/runner.html b/src/fauxton/test/runner.html
index 5a29ef1..b86855e 100644
--- a/src/fauxton/test/runner.html
+++ b/src/fauxton/test/runner.html
@@ -7,6 +7,7 @@
   <body>
     <div id="mocha"></div>
     <script type="text/javascript" src="mocha/mocha.js"></script>
+    <script type="text/javascript" src="mocha/sinon.js"></script>
     <script type="text/javascript">
       // MOCHA SETUP
       mocha.setup('bdd');

http://git-wip-us.apache.org/repos/asf/couchdb/blob/c88b72a9/src/fauxton/test/test.config.js
----------------------------------------------------------------------
diff --git a/src/fauxton/test/test.config.js b/src/fauxton/test/test.config.js
index 54f976e..f876bb3 100644
--- a/src/fauxton/test/test.config.js
+++ b/src/fauxton/test/test.config.js
@@ -13,7 +13,9 @@ require.config(
 		"jshint": "../assets/js/libs/jshint",
 		"d3": "../assets/js/libs/d3",
 		"nv.d3": "../assets/js/libs/nv.d3",
-		"chai": "../test/mocha/chai"
+		"chai": "../test/mocha/chai",
+		"sinon-chai": "../test/mocha/sinon-chai",
+		"testUtils": "../test/mocha/testUtils"
 	},
 	"baseUrl": "../app",
 	"shim": {


Mime
View raw message