Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Testing #27

Closed
xwilders opened this issue Dec 5, 2016 · 1 comment
Closed

Testing #27

xwilders opened this issue Dec 5, 2016 · 1 comment

Comments

@xwilders
Copy link

xwilders commented Dec 5, 2016

I'm looking to incorporate testing into the build process.

At what point should the following command be run? I've forked this repository and tried adding it after meteor gets installed in build-meteor.sh, but the command seems to be ignored (the build succeeds but the logs show no trace of the tests running):

meteor test --once --driver-package dispatch:mocha-phantomjs

@jshimko
Copy link
Owner

jshimko commented Dec 10, 2016

Testing isn't usually something you do inside your Docker image. You should do that in a continuous integration workflow before building the image. Check out CircleCI.

A Circle config might look something like this:

machine:
  node:
    version: 4.6.2
  services:
    - docker
  pre:
    - hash meteor 2>/dev/null || curl https://install.meteor.com | sh

dependencies:
  cache_directories:
    - "~/.meteor"
  override:
    - meteor npm install

test:
  override:
    - meteor test --once --driver-package dispatch:mocha-phantomjs

deployment:
  release:
    branch: master
    commands:
      - docker build -t yourorg/appname:latest .
      - docker login -e $DOCKER_EMAIL -u $DOCKER_USER -p $DOCKER_PASS
      - docker push yourorg/appname:latest

@jshimko jshimko closed this as completed Dec 10, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants