wercker.yml

Summary

Maintainability
Test Coverage
# This references the default nodejs container from
# the Docker Hub: https://registry.hub.docker.com/_/node/
# If you want Nodesource's container you would reference nodesource/node
# Read more about containers on our dev center
# http://devcenter.wercker.com/docs/containers/index.html
box: node:6
# This is the build pipeline. Pipelines are the core of wercker
# Read more about pipelines on our dev center
# http://devcenter.wercker.com/docs/pipelines/index.html

# You can also use services such as databases. Read more on our dev center:
# http://devcenter.wercker.com/docs/services/index.html
# services:
    # - postgres
    # http://devcenter.wercker.com/docs/services/postgresql.html

    # - mongo
    # http://devcenter.wercker.com/docs/services/mongodb.html
build:
  # The steps that will be executed on build
  # Steps make up the actions in your pipeline
  # Read more about steps on our dev center:
  # http://devcenter.wercker.com/docs/steps/index.html
  steps:
    #Firefox, Java and xvfb for e2e tests
#    - script:
#        name: install firefox
#        code: |-
          # sudo apt-get install --assume-yes build-essential curl wget libfreetype6-dev libfontconfig1-dev xvfb x11-xkb-utils xfonts-100dpi xfonts-75dpi xfonts-scalable xfonts-cyrillic x11-apps
#          cd /usr/local
#          wget http://ftp.mozilla.org/pub/firefox/releases/50.1.0/linux-x86_64/en-US/firefox-50.1.0.tar.bz2
#          tar xvjf firefox-50.1.0.tar.bz2
#          sudo ln -s /usr/local/firefox/firefox /usr/bin/firefox
#    - script:
#        name: install java
#        code: |-
#          echo deb http://http.debian.net/debian jessie-backports main >> /etc/apt/sources.list
#          apt-get -y update && apt-get -y install openjdk-8-jdk
#          update-alternatives --config java
#    - script:
#        name: test java
#        code: |-
#          type java || { echo "I expected java to be available after oracle-java7-installer installation. Aborting."; exit 1; }
#    - script:
#        name: start virtual display xvfb
#        code: |-
#          sudo apt-get --assume-yes install xvfb -y
#          sleep 15
#          export DISPLAY=:99.0
#          sudo start-stop-daemon --start --quiet --pidfile /tmp/xvfb_99.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :99 -screen 0 1024x768x24 -ac +extension GLX +render -noreset
#          sleep 15
#          xdpyinfo -display :0 >/dev/null 2>&1 && echo "In use" || echo "Free"

    # A step that executes `npm install` command
    - npm-install
    # A step that executes `npm test` command
    - npm-test
#    - script:
#        name: npm run unit
#        code: |
#          node run unit

    # A custom script step, name value is used in the UI
    # and the code value contains the command that get executed
    - script:
        name: echo nodejs information
        code: |
          echo "node version $(node -v) running"
          echo "npm version $(npm -v) running"

    # A custom script step, name value is used in the UI
    # and the code value contains the command that get executed
    - maxon/npm-run:
        script: build

deploy-firebase:
  steps:
    - devillex/firebase-deploy@1.0.0:
        project: $FIREBASE_PROJECT_NAME
        token: $FIREBASE_TOKEN