diff --git a/pree2e.sh b/pree2e.sh index fbe3b1a87..5cb14287b 100755 --- a/pree2e.sh +++ b/pree2e.sh @@ -1,4 +1,4 @@ node_modules/selenium-standalone/bin/selenium-standalone install source .env-test -echo $TALK_MONGO_URL +node tests/e2e/mocks & npm start & diff --git a/tests/e2e/mocks.js b/tests/e2e/mocks.js new file mode 100644 index 000000000..6abb2b6fe --- /dev/null +++ b/tests/e2e/mocks.js @@ -0,0 +1,20 @@ +const Comments = require('../../models/comment') +const Users = require('../../models/user') +const Actions = require('../../models/action') + +const mockComments = [ + { + body: 'Pangolin pups are called pangopups.', + author_id: '123', + id: 'abc' + }, + { + body: 'Baby whales grow at up to 8lbs an hour.', + author_id: '456', + id: 'def' + } +]; + +console.log('Loading mocks.'); + +Comments.create(mockComments);