language: python
python:
    - "2.7"
before_install:
    - "export DISPLAY=:99"
    - "sh -e /etc/init.d/xvfb start"
install:
    - "pip install -e git://github.com/edx/xblock-sdk.git#egg=xblock-sdk"
    - "pip install -r requirements.txt"
    - "pip install -r $VIRTUAL_ENV/src/xblock-sdk/requirements.txt"
    - "pip install -r $VIRTUAL_ENV/src/xblock-sdk/test-requirements.txt"
    - "pip uninstall -y xblock-problem-builder && python setup.py sdist && pip install dist/xblock-problem-builder-2.0.tar.gz"
    - "pip install -r test_requirements.txt"
script:
    - pep8 problem_builder --max-line-length=120
    - pylint problem_builder --disable=all --enable=function-redefined,undefined-variable,unused-variable
    - python run_tests.py --with-coverage --cover-package=problem_builder
notifications:
  email: false
addons:
  firefox: "36.0"
