Skip to content

Commit

Permalink
removing irrelevant tests that are now being tested in their individu…
Browse files Browse the repository at this point in the history
…al repos. Switching to tape for tests.
  • Loading branch information
HenrikJoreteg committed Apr 10, 2014
1 parent a08a1ac commit b62f14a
Show file tree
Hide file tree
Showing 28 changed files with 141 additions and 31,001 deletions.
6 changes: 1 addition & 5 deletions .jshintignore
@@ -1,6 +1,2 @@
node_modules
ampersand-model.min.js
ampersand-model.bundle.js
test.js
idealUse.js
test/*
test/model.js
15 changes: 9 additions & 6 deletions README.md
Expand Up @@ -24,6 +24,10 @@ via bower:
bower install ampersand-model
```

## Browser compatibility

[![testling badge](https://ci.testling.com/ampersandjs/ampersand-model.png)](https://ci.testling.com/ampersandjs/ampersand-model)


## Types of state

Expand Down Expand Up @@ -237,14 +241,13 @@ user.get('firstName');
user.firstName;
```

## Tests

An extensive suite of tests can be run by opening `test/index.html` in a browser. In order to ensure compatibility with backbone to the extent possible we started with all the tests from Backbone 1.0.0 and modified them to use ampersand-model.
## Running the tests

## Caveats
```
npm test
```

- Since backbone does an `instanceof` check when adding initted models to a collection, ampersand-model monkey patches the `_prepareModel` collection method to check against ampersand-model instead.
- Still needs better docs. Probably a full docs site.
*note*: Much of the functionality of ampersand-model is actually inherited from [ampersand-state](https://github.com/ampersandjs/ampersand-state) and is tested seperately there. In order to ensure compatibility with backbone to the extent possible we started with all the tests from Backbone and modified them to use ampersand-model. But over time they've been spread out and converted to be run with [tape](https://github.com/substack/tape) so we can automatically test against many browser versions with testling.


## Module: ampersand-model
Expand Down

0 comments on commit b62f14a

Please sign in to comment.