From cb37830cd647833646d4b0ea37693bb436773260 Mon Sep 17 00:00:00 2001 From: Josh Lubaway Date: Mon, 16 Sep 2013 14:11:03 -0700 Subject: [PATCH] Updating testing & distribution documentation. We've moved to a `Makefile` and some of the documentation fell out of date. This corrects the outdated docs. --- CONTRIBUTING.md | 16 ++++++++++++++++ Makefile | 2 +- README.md | 21 ++++++++++++++------- spec/{suite.html => runner.html} | 0 4 files changed, 31 insertions(+), 8 deletions(-) create mode 100644 CONTRIBUTING.md rename spec/{suite.html => runner.html} (100%) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..70f7754 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,16 @@ +# Contributing to Ember Resource + +We're glad you're interested in contributing to the Ember Resource project! There are a number of ways in which you can contribute! + +* Submit issues to our [issue tracker][1] +* Use Ember Resource in your own project and let us know how it works for you +* Open a pull request and contribute some of your own code + +### Pull Requests + +We love pull requests. Please make sure to run the tests locally (`open spec/runner.html` for browser tests or `make test` on the command line) before pushing your branch . But don't worry, even if you forget [Travis CI][2] should run the tests on the pull request for you. + +Submit your pull request! + +[1]: https://github.com/zendesk/ember-resource/issues +[2]: https://travis-ci.org/zendesk/ember-resource/ diff --git a/Makefile b/Makefile index 81b4d84..9b5fbf1 100644 --- a/Makefile +++ b/Makefile @@ -14,7 +14,7 @@ jshint: npm_install $(JSHINT) src/*.js src/vendor/*.js spec/javascripts/*Spec.js test: jshint npm_install - ./node_modules/mocha-phantomjs/bin/mocha-phantomjs spec/suite.html + ./node_modules/mocha-phantomjs/bin/mocha-phantomjs spec/runner.html npm_install: npm install diff --git a/README.md b/README.md index 973ec8f..3421ab9 100644 --- a/README.md +++ b/README.md @@ -178,21 +178,28 @@ describing the action that occurred (one of ## Testing -Currently the command line test runners are in a state of disrepair :( To run -the Ember Resource test suite, just open `spec/runner.html` in your favorite -browser. +Tests can be run from the command line, or in a browser: + +### Browser + +To run the Ember Resource test suite in a browser, just open `spec/runner.html` +in your favorite browser. On Mac OS: open spec/runner.html +### Command line + +To run the test suite from the command line run the `make test` command: + + make test + ## Building a distribution -There is a rake task to generate an asset for distribution. +To build your very own copy of Ember Resource run the `make dist` task: -``` - rake dist:build -``` + make dist The output will be put in the `dist/` folder. diff --git a/spec/suite.html b/spec/runner.html similarity index 100% rename from spec/suite.html rename to spec/runner.html