diff options
author | Juan Felipe Torres <juanto121@hotmail.com> | 2015-04-18 20:11:47 -0500 |
---|---|---|
committer | Juan Felipe Torres <juanto121@hotmail.com> | 2015-04-18 20:11:47 -0500 |
commit | 3242fa604a991f15f98b95809174dd3ef06c6d6c (patch) | |
tree | 073c3732d02bf9901719c33584b7085df62ad123 | |
parent | 6d8239e3295ca49d51f8764b82a56dcf9f81dd8e (diff) | |
download | awesomplete-3242fa604a991f15f98b95809174dd3ef06c6d6c.zip awesomplete-3242fa604a991f15f98b95809174dd3ef06c6d6c.tar.gz awesomplete-3242fa604a991f15f98b95809174dd3ef06c6d6c.tar.bz2 |
Intro to test on readme
-rw-r--r-- | README.md | 22 | ||||
-rw-r--r-- | tests/jasmine/index.html (renamed from tests/jasmine/SpecRunner.html) | 0 |
2 files changed, 21 insertions, 1 deletions
@@ -1,4 +1,4 @@ -# Awesomplete
+|# Awesomplete
http://leaverou.github.io/awesomplete/
@@ -57,6 +57,26 @@ Or the following, if you don’t want to use a `<datalist>`, or if you don’t w There are multiple customizations and properties able to be instantiated within the JS. Libraries and definitions of the properties are available in the Links below.
+##Contributing
+**Adding a test**
+
+Jasmine is the testing framework used by Awesomplete. The setup is really simple, fire the [runner](tests/jasmine/index.html) on a browser and write your tests on the [spec](tests/jasmine/spec/awesompleteSpec.js).
+
+To write a test (or suite of tests) start by adding a `describe` function which receives a string describing what is being tested and a function containing what you expect the test to do. Inside the function use the `it` block to arrange and assert a functionality.
+
+A test would look like this:
+
+```javascript
+describe("A fact", function(){
+ it("is always true",function(){
+ var fact = true;
+ expect(fact).toBe(true);
+ });
+});
+```
+
+More expectations and examples on how to use Jasmine can be found on the official [documentation](http://jasmine.github.io/2.2/introduction.html).
+
## License
Awesomplete is released under the MIT License. See [LICENSE][1] file for
diff --git a/tests/jasmine/SpecRunner.html b/tests/jasmine/index.html index 2411e17..2411e17 100644 --- a/tests/jasmine/SpecRunner.html +++ b/tests/jasmine/index.html |