carkraus  committed 927fa27

add readme

  • Participants
  • Parent commits 8833f7c

Comments (0)

Files changed (2)

+Little example setup on how one can easily use the great plovr tool also for unit testing your js code.
+To get started download or build plovr and clone this repo.
+Next, start plovr in serve mode by pointing it to the tests/plovr.json file::
+	cd <yourclone>
+	java -jar <path/to/plovr.jar> serve tests/plovr.json
+Then you should be able to browse tests/all.html and run the example tests in src/foo_test.html.
+To add own tests, well write some .) and have a look into all.html: you'll find the array 'allTests'.
+Put references to your test files into this var and add the requirements of your units and test into tests/deps.js.

File tests/all.html

-      var _allTests = [
+      var allTests = [
         //    "closure/goog/asserts/asserts_test.html",
         //    "closure/goog/async/conditionaldelay_test.html",
           .setStatsBucketSizes(5, 500)
-          .addTests(_allTests);
+          .addTests(allTests);
       testRunner.render(document.getElementById('runner'));, 'click', function(e) {