[tox]
passenv = TRAVIS
usedevelop=True
basepython = python2.7
envlist = py

[testenv:itests]
passenv = TRAVIS MARATHONVERSION
basepython = python2.7
whitelist_externals=/bin/bash
skipsdist=True
changedir=itests/
deps =
    requests<2.7
    {[testenv]deps}
    docker-compose==1.3.1
    behave
    mock
commands =
    /bin/bash -c "[[ -n $TRAVIS ]] || echo MARATHONVERSION=$MARATHONVERSION > marathon-version"
    /bin/bash -c "[[ -n $TRAVIS ]] || docker-compose build"
    /bin/bash -c "[[ -n $TRAVIS ]] || docker-compose pull"
    /bin/bash -c "[[ -n $TRAVIS ]] || docker-compose up -d"
    behave {posargs}
    /bin/bash -c "[[ -n $TRAVIS ]] || docker-compose stop"
    /bin/bash -c "[[ -n $TRAVIS ]] || docker-compose rm --force"

[testenv]
usedevelop=True
basepython = python2.7
install_command = pip install --upgrade {opts} {packages}
deps = -rrequirements.txt

[testenv:py]
recreate=True
basepython = python2.7
deps =
  {[testenv]deps}
  pytest
  mock
commands =
  py.test -s {posargs:tests}



[tox]
passenv = TRAVIS
usedevelop=True
basepython = python2.7
envlist = py

[testenv:itests]
passenv = TRAVIS MARATHONVERSION DOCKER_HOST DOCKER_TLS_VERIFY DOCKER_CERT_PATH DOCKER_MACHINE_NAME
basepython = python2.7
whitelist_externals=/bin/bash
skipsdist=True
changedir=itests/
deps =
    requests<2.7
    {[testenv]deps}
    docker-compose==1.3.1
    behave
    mock
commands =
    /bin/bash -c "[[ -n $TRAVIS ]] || echo MARATHONVERSION=$MARATHONVERSION > marathon-version"
    /bin/bash -c "[[ -n $TRAVIS ]] || docker-compose build"
    /bin/bash -c "[[ -n $TRAVIS ]] || docker-compose pull"
    /bin/bash -c "[[ -n $TRAVIS ]] || docker-compose up -d"
    behave {posargs}
    /bin/bash -c "[[ -n $TRAVIS ]] || docker-compose stop"
    /bin/bash -c "[[ -n $TRAVIS ]] || docker-compose rm --force"

[testenv]
usedevelop=True
basepython = python2.7
install_command = pip install --upgrade {opts} {packages}
deps = -rrequirements.txt

[testenv:py]
recreate=True
basepython = python2.7
deps =
  {[testenv]deps}
  pytest
  mock
commands =
  py.test -s {posargs:tests}



Make it possible to run itests at osx with docker-machine
Make it possible to run itests at osx with docker-machine
