This repository has been archived by the owner on Jun 18, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
99 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
__pycache__/ | ||
*.py[cod] | ||
vectordraw_xblock.egg-info/ | ||
var/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
language: python | ||
python: | ||
- 2.7 | ||
before_install: | ||
- export DISPLAY=:99 | ||
- sh -e /etc/init.d/xvfb start | ||
install: | ||
- pip install -r test-requirements.txt | ||
- pip install -r $VIRTUAL_ENV/src/xblock-sdk/requirements/base.txt | ||
- pip install -r $VIRTUAL_ENV/src/xblock-sdk/requirements/test.txt | ||
- pip install -r $VIRTUAL_ENV/src/xblock/requirements.txt | ||
script: | ||
- pep8 --max-line-length=100 vectordraw | ||
- pylint vectordraw | ||
- ./run_tests.py --with-coverage --cover-package=vectordraw | ||
notifications: | ||
email: false | ||
addons: | ||
firefox: 36.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
[REPORTS] | ||
reports=no | ||
|
||
[FORMAT] | ||
max-line-length=100 | ||
|
||
[MESSAGES CONTROL] | ||
disable= | ||
I, | ||
attribute-defined-outside-init, | ||
maybe-no-member, | ||
star-args, | ||
too-few-public-methods, | ||
too-many-ancestors, | ||
too-many-instance-attributes, | ||
too-many-public-methods | ||
|
||
[VARIABLES] | ||
dummy-variables-rgx=_$|dummy|unused |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
django>=1.4, <1.5 | ||
pyyaml | ||
-e git+https://github.com/edx/XBlock.git@tag-master-2015-05-22#egg=XBlock | ||
-e git+https://github.com/edx/xblock-utils.git@b4f9b51146c7fafa12f41d54af752b8f1516dffd#egg=xblock-utils | ||
-e . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
#!/usr/bin/env python | ||
# -*- coding: utf-8 -*- | ||
"""Run tests for the Vector Drawing XBlock. | ||
This script is required to run our selenium tests inside the xblock-sdk workbench | ||
because the workbench SDK's settings file is not inside any python module. | ||
""" | ||
|
||
import os | ||
import logging | ||
import sys | ||
|
||
from django.conf import settings | ||
from django.core.management import execute_from_command_line | ||
|
||
logging_level_overrides = { | ||
'workbench.views': logging.ERROR, | ||
'django.request': logging.ERROR, | ||
'workbench.runtime': logging.ERROR, | ||
} | ||
|
||
if __name__ == '__main__': | ||
# Use the workbench settings file: | ||
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'workbench.settings') | ||
# Configure a range of ports in case the default port of 8081 is in use | ||
os.environ.setdefault('DJANGO_LIVE_TEST_SERVER_ADDRESS', 'localhost:8081-8099') | ||
|
||
try: | ||
os.mkdir('var') | ||
except OSError: | ||
# May already exist. | ||
pass | ||
|
||
settings.INSTALLED_APPS += ('vectordraw', ) | ||
|
||
for noisy_logger, log_level in logging_level_overrides.iteritems(): | ||
logging.getLogger(noisy_logger).setLevel(log_level) | ||
|
||
args_iter = iter(sys.argv[1:]) | ||
options = [] | ||
paths = [] | ||
for arg in args_iter: | ||
if arg == '--': | ||
break | ||
if arg.startswith('-'): | ||
options.append(arg) | ||
else: | ||
paths.append(arg) | ||
paths.extend(args_iter) | ||
if not paths: | ||
paths = ['tests/'] | ||
execute_from_command_line([sys.argv[0], 'test'] + options + ['--'] + paths) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
-r requirements.txt | ||
-e git+https://github.com/edx/xblock-sdk.git@629650ed6fc1b77d1a5287debeace0b29db7c0fd#egg=xblock-sdk |
Empty file.
Empty file.
Empty file.