Commit b42291da by Sven Marnach

Fix build and test failures

* Remove duplications in requirements installation
* Change directory to install xblock-sdk requirements
* Update xblock-utils hash to latest version
* Silence pylint import error
* Remove requirements that are not on PyPI from setup.py
* Fix CSS selector for a <button> that used to be an <a> in Selenium test
* Add img alt attributes to XML test data
parent 2a0771eb
......@@ -6,7 +6,6 @@ before_install:
- "sh -e /etc/init.d/xvfb start"
install:
- "sh install_test_deps.sh"
- "python setup.py develop"
script: pep8 poll --max-line-length=120 && pylint poll && python run_tests.py --with-coverage --cover-package=poll
notifications:
email: false
# Installs xblock-sdk and dependencies needed to run the tests suite.
# Run this script inside a fresh virtual environment.
pip install -e git://github.com/edx/xblock-sdk.git#egg=xblock-sdk
pip install -r $VIRTUAL_ENV/src/xblock-sdk/requirements.txt
cd $VIRTUAL_ENV/src/xblock-sdk/ && { pip install -r requirements.txt; cd -; }
pip install -r $VIRTUAL_ENV/src/xblock-sdk/test-requirements.txt
python setup.py develop
pip install -r requirements.txt
......@@ -46,6 +46,7 @@ except ImportError:
HAS_GROUP_PROFILE = False
try:
# pylint: disable=import-error
from static_replace import replace_static_urls
HAS_STATIC_REPLACE = True
except ImportError:
......
-e .
markdown
-e git+https://github.com/edx/xblock-utils.git@db22bc40fd2a75458a3c66d057f88aff5a7383e6#egg=xblock-utils
-e git://github.com/edx/xblock-utils.git@213a97a50276d6a2504d8133650b2930ead357a0#egg=xblock-utils
-e git://github.com/nosedjango/nosedjango.git@ed7d7f9aa969252ff799ec159f828eaa8c1cbc5a#egg=nosedjango-dev
ddt
mock
-e .
......@@ -50,9 +50,7 @@ setup(
'poll',
],
install_requires=[
'XBlock',
'markdown',
'xblock-utils',
'ddt',
'mock',
],
......
......@@ -121,7 +121,7 @@ class TestPrivateResults(PollBaseTest):
@stub_view_permission(True)
def test_results_button(self, page_name, names):
self.go_to_page(page_name)
button = self.browser.find_element_by_css_selector('a.view-results-button')
button = self.browser.find_element_by_css_selector('.view-results-button')
button.click()
self.wait_until_exists('.poll-results')
self.wait_until_exists('.poll-footnote')
<poll tally='{"red": 20, "fennec": 29, "kit": 15, "arctic" : 35}'
question="## What is your favorite kind of fox?"
answers='[["red", {"label": "Red Fox", "img": "../img/red_fox.png"}], ["fennec", {"label": "Fennec Fox", "img": "../img/fennec_fox.png"}], ["kit", {"label": "Kit Fox", "img": "../img/kit_fox.png"}], ["arctic", {"label": "Arctic fox", "img": "../img/arctic_fox.png"}]]' />
answers='[["red", {"label": "Red Fox", "img": "../img/red_fox.png", "img_alt": "Red Fox"}], ["fennec", {"label": "Fennec Fox", "img": "../img/fennec_fox.png", "img_alt": "Fennec Fox"}], ["kit", {"label": "Kit Fox", "img": "../img/kit_fox.png", "img_alt": "Kit Fox"}], ["arctic", {"label": "Arctic Fox", "img": "../img/arctic_fox.png", "img_alt": "Arctic Fox"}]]' />
<poll tally="{'red': 20, 'fennec': 29, 'kit': 15, 'arctic' : 35}"
question="## What is your favorite kind of fox?"
answers='[["red", {"label": "Red Fox", "img": null}], ["fennec", {"label": "Fennec Fox", "img": "../img/fennec_fox.png"}], ["kit", {"label": "Kit Fox", "img": null}], ["arctic", {"label": "Arctic fox", "img": null}]]' />
answers='[["red", {"label": "Red Fox", "img": null}], ["fennec", {"label": "Fennec Fox", "img": "../img/fennec_fox.png", "img_alt": "Fennec Fox"}], ["kit", {"label": "Kit Fox", "img": null}], ["arctic", {"label": "Arctic fox", "img": null}]]' />
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment