Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Steur <tsteur@users.noreply.github.com>2014-03-31 01:04:59 +0400
committerThomas Steur <tsteur@users.noreply.github.com>2014-03-31 01:04:59 +0400
commit29cee449fe69e9aaf59c47471fc6ea6fa79e3d5e (patch)
tree2ea7854d8450c28a3d808871dbea76d57eb431fc /tests/angularjs
parent275b6b0f0a771aa480ec0b5fc7265487263aa464 (diff)
added file structure
Diffstat (limited to 'tests/angularjs')
-rw-r--r--tests/angularjs/README.md10
1 files changed, 9 insertions, 1 deletions
diff --git a/tests/angularjs/README.md b/tests/angularjs/README.md
index edcd91f452..fd8465c4b7 100644
--- a/tests/angularjs/README.md
+++ b/tests/angularjs/README.md
@@ -15,6 +15,14 @@ On Ubuntu you might be able to use the `scripts/install-ubuntu.sh` script. Have
* [Mocha](http://visionmedia.github.io/mocha/)
* You need more assertions? Have a look at [Chai plugins](http://chaijs.com/plugins)
+## File structure
+
+We do not have a general `tests` folder containing all test files. Instead we create a file having the same name appended by "_test.js" in the same directory.
+
+For instance you want to test a file named `startfrom.js` then we create a file named `startfrom_test.js`:
+`plugins/CoreHome/angularjs/common/filters/startfrom.js` =>
+`plugins/CoreHome/angularjs/common/filters/startfrom_test.js`
+
## Execution
Run tests and run them automatically again once there is a file change:
@@ -31,7 +39,7 @@ You can change the `browsers: ['Chrome', 'Firefox', 'PhantomJS']` property in `k
## Testing existing jQuery code
-TBD
+Just in case you want to write a test for your jQuery code you can do this the same way. You might be interested in the [Chai jQuery](http://chaijs.com/plugins/chai-jquery) plugin.
## Examples
* [Testing a filter](plugins/CoreHome/angularjs/common/filters/startfrom_test.js)