Skip to content

Commit

Permalink
Add unit tests (#68)
Browse files Browse the repository at this point in the history
* initial tests and move around

* only build master branch

* support testing multiple versions of react in jest/enzyme

* add more tests, run multiple react versions in ci

* add more tests

* fix test with workaround

* add more proptype tests

* move danger to ci script
  • Loading branch information
danreeves authored Feb 18, 2018
1 parent 6ee961b commit 5d29384
Show file tree
Hide file tree
Showing 9 changed files with 3,077 additions and 53 deletions.
7 changes: 5 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
language: node_js
node_js: "stable"
branches:
only:
- master

before_install:
- "stty cols 80"
- "export SAUCE_JOB=react-tether"
- "export SAUCE_BUILD=$TRAVIS_COMMIT"

before_script:
- npm run danger
script:
- ./bin/test
17 changes: 17 additions & 0 deletions bin/test
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/usr/bin/env bash

npm run danger

npm run react:15
npm run unit

npm run react:16
npm run unit

if [ -z "$SAUCE_USERNAME" ] && [ -z "$SAUCE_ACCESS_KEY"]; then
echo
echo "ATTENTION"
echo "Skipping E2E tests because the environment variables are not set!"
else
npm run e2e:full
fi
Loading

0 comments on commit 5d29384

Please sign in to comment.