Skip to content

Commit

Permalink
Init JS tests with Mocha
Browse files Browse the repository at this point in the history
Add tests for streams.js

Closes #25
  • Loading branch information
jaywink committed Aug 28, 2016
1 parent 44402b4 commit 96d2178
Show file tree
Hide file tree
Showing 16 changed files with 443 additions and 197 deletions.
12 changes: 6 additions & 6 deletions .gitignore
Expand Up @@ -70,14 +70,14 @@ mailhog
# Socialhome environment file
env.local

# Compiled CSS
# Collected statics
socialhome/static/css/*.css

# Compiled JS
socialhome/static/js/project.js
socialhome/static/fonts/
staticfiles/

# Bower
/bower_components/
bower_components/

# Collected fonts
socialhome/static/fonts/
# Mocha test statics
socialhome/static/mocha/
11 changes: 9 additions & 2 deletions .travis.yml
Expand Up @@ -20,8 +20,15 @@ before_script:
- npm install
- bower install
- node_modules/.bin/grunt build
script: py.test --cov=./
- python manage.py print_settings
script:
- py.test --cov=./
- python manage.py migrate --noinput -v 0
- python manage.py collectstatic --noinput -v 0
- python manage.py runserver 8000 &
- sleep 5 # wait for server to start
- node_modules/.bin/grunt mocha
after_success:
- codecov
env:
- DATABASE_URL=postgres://postgres@127.0.0.1:5432/travis_ci_test DJANGO_SETTINGS_MODULE=config.settings.local DJANGO_ALLOWED_HOSTS=127.0.0.1 DJANGO_SECURE_SSL_REDIRECT=False SOCIALHOME_DOMAIN=127.0.0.1:8000 SOCIALHOME_HTTPS=False DJANGO_DEBUG=False DJANGO_DEBUG_TOOLBAR=False
- DATABASE_URL=postgres://postgres@127.0.0.1:5432/travis_ci_test DJANGO_SETTINGS_MODULE=config.settings.local DJANGO_ALLOWED_HOSTS=127.0.0.1 DJANGO_SECURE_SSL_REDIRECT=False SOCIALHOME_DOMAIN=127.0.0.1:8000 SOCIALHOME_HTTPS=False DJANGO_DEBUG=False DJANGO_DEBUG_TOOLBAR=False MOCHA_TESTS=True

0 comments on commit 96d2178

Please sign in to comment.