Skip to content

Commit

Permalink
add more test version for connect
Browse files Browse the repository at this point in the history
  • Loading branch information
fengmk2 committed Dec 7, 2012
1 parent 4670799 commit 2abdf02
Show file tree
Hide file tree
Showing 6 changed files with 37 additions and 1,052 deletions.
6 changes: 6 additions & 0 deletions .npmignore
@@ -0,0 +1,6 @@
test/
coverage.html
lib-cov/
Makefile
.travis.yml
logo.png
28 changes: 16 additions & 12 deletions Makefile
@@ -1,29 +1,33 @@
TESTS = test/*.js
TESTTIMEOUT = 1000
TIMEOUT = 1000
REPORTER = spec
SUPPORT_VERSIONS := 1.9.2 1.9.1 1.9.0 1.8.0 1.8.5 1.8.6 1.8.7 \
2.2.0 2.2.1 2.2.2 \
2.3.0 2.3.1 2.3.2 2.3.3 2.3.4 2.3.5 2.3.6 2.3.7 2.3.8 2.3.9 \
2.4.0 2.4.1 2.4.2 2.4.3 2.4.4 2.4.5 2.4.6
2.4.0 2.4.1 2.4.2 2.4.3 2.4.4 2.4.5 2.4.6 \
2.5.0 \
2.6.0 2.6.1 2.6.2 \
2.7.0 2.7.1
JSCOVERAGE = ./node_modules/jscover/bin/jscover

test:
@NODE_ENV=test ./node_modules/.bin/mocha -R $(REPORTER) --timeout $(TESTTIMEOUT) $(TESTS)
@NODE_ENV=test ./node_modules/mocha/bin/mocha \
--reporter $(REPORTER) \
--timeout $(TIMEOUT) \
$(TESTS)

test-cov:
@rm -rf lib-cov
@jscoverage lib lib-cov
lib-cov:
@rm -rf $@
@$(JSCOVERAGE) lib $@

test-cov: lib-cov
@URLROUTER_COV=1 $(MAKE) test REPORTER=dot
@URLROUTER_COV=1 $(MAKE) test REPORTER=html-cov > coverage.html
@$(MAKE) test-results

test-results:
@$(MAKE) test REPORTER=markdown > test_results.md
@echo "> test_results.md done."

test-version:
@for version in $(SUPPORT_VERSIONS); do \
npm install connect@$$version --loglevel=warn; \
$(MAKE) test REPORTER=min; \
done

.PHONY: test test-cov test-version test-results
.PHONY: test test-cov lib-cov test-version test-results
18 changes: 14 additions & 4 deletions README.md
Expand Up @@ -17,6 +17,7 @@ Support `connect` @1.8.x and @2.2.0+ .
* 2.2.0+
* 2.3.0+
* 2.4.0+
* 2.7.0+

```bash
$ make test-version
Expand Down Expand Up @@ -153,11 +154,20 @@ http.createServer(routerMiddleware).listen(3000);
```

## Contributors
Ordered by date of first contribution.
[Auto-generated](http://github.com/dtrejo/node-authors) on Thu Sep 13 2012 10:49:38 GMT+0800 (CST).

- [fengmk2](https://github.com/fengmk2)
- [rockdai](https://github.com/rockdai)
```bash
$ git summary

project : urlrouter
repo age : 6 months
active : 10 days
commits : 25
files : 19
authors :
20 fengmk2 80.0%
4 rockdai 16.0%
1 rock 4.0%
```

## License

Expand Down

0 comments on commit 2abdf02

Please sign in to comment.