Using setup.py nosetests to run tests
This commit is contained in:
parent
6dce6df6b2
commit
301dce2dd1
|
|
@ -9,9 +9,8 @@ before_install:
|
|||
- rm -rf ~/.npm
|
||||
- mkdir ~/.npm
|
||||
install:
|
||||
- pip wheel -w $HOME/.wheelhouse -f $HOME/.wheelhouse -r requirements.txt
|
||||
- pip install --find-links=$HOME/.wheelhouse --no-index -rrequirements.txt
|
||||
- python setup.py install
|
||||
- pip wheel -w $HOME/.wheelhouse -f $HOME/.wheelhouse .
|
||||
- pip install --find-links=$HOME/.wheelhouse --no-index .
|
||||
- cd dashed/assets
|
||||
- npm install
|
||||
- npm run lint
|
||||
|
|
@ -20,4 +19,3 @@ install:
|
|||
script: bash run_tests.sh
|
||||
after_success:
|
||||
- coveralls
|
||||
- cd dashed/assets
|
||||
|
|
|
|||
|
|
@ -150,10 +150,11 @@ function nvd3Vis(slice) {
|
|||
xAxisFormatter = d3.format('.3s');
|
||||
} else if (fd.x_axis_format === 'smart_date') {
|
||||
xAxisFormatter = px.formatDate;
|
||||
chart.xAxis.tickFormat(xAxisFormatter);
|
||||
} else if (fd.x_axis_format !== undefined) {
|
||||
xAxisFormatter = px.timeFormatFactory(fd.x_axis_format);
|
||||
chart.xAxis.tickFormat(xAxisFormatter);
|
||||
}
|
||||
chart.xAxis.tickFormat(xAxisFormatter);
|
||||
|
||||
if (chart.hasOwnProperty("x2Axis")) {
|
||||
chart.x2Axis.tickFormat(xAxisFormatter);
|
||||
|
|
|
|||
|
|
@ -581,7 +581,7 @@ class BigNumberViz(BaseViz):
|
|||
def get_data(self):
|
||||
form_data = self.form_data
|
||||
df = self.get_df()
|
||||
df = df.sort(columns=df.columns[0])
|
||||
df.sort(columns=df.columns[0], inplace=True)
|
||||
compare_lag = form_data.get("compare_lag", "")
|
||||
compare_lag = int(compare_lag) if compare_lag and compare_lag.isdigit() else 0
|
||||
return {
|
||||
|
|
@ -802,7 +802,7 @@ class DistributionPieViz(NVD3Viz):
|
|||
df = df.pivot_table(
|
||||
index=self.groupby,
|
||||
values=[self.metrics[0]])
|
||||
df = df.sort(self.metrics[0], ascending=False)
|
||||
df.sort(self.metrics[0], ascending=False, inplace=True)
|
||||
return df
|
||||
|
||||
def get_data(self):
|
||||
|
|
|
|||
|
|
@ -0,0 +1,2 @@
|
|||
sphinx
|
||||
sphinx_bootstrap_theme
|
||||
|
|
@ -1,28 +0,0 @@
|
|||
alembic>=0.7.7, <0.8.0
|
||||
sphinx
|
||||
sphinx_bootstrap_theme
|
||||
coverage
|
||||
coveralls
|
||||
flask==0.10.1
|
||||
flask-appbuilder>=1.4.5, <2.0.0
|
||||
flask-login==0.2.11
|
||||
flask-migrate>=1.5.1, <2.0.0
|
||||
flask-script>=2.0.5, <3.0.0
|
||||
flask-testing>=0.4.2, <0.5.0
|
||||
flask-sqlalchemy==2.0
|
||||
gunicorn>=19.3.0, <20.0.0
|
||||
markdown>=2.6.2, <3.0.0
|
||||
nose
|
||||
numpy>=1.9
|
||||
pandas==0.16.2
|
||||
parsedatetime>=1.5, <2.0.0
|
||||
pydruid>=0.2.2, <0.3
|
||||
python-dateutil>=2.4.2, <3.0.0
|
||||
requests>=2.7.0, <3.0.0
|
||||
sqlparse>=0.1.16, <0.2.0
|
||||
pyhive
|
||||
Sphinx-PyPI-upload
|
||||
sphinxcontrib.youtube
|
||||
mysqlclient>=1.3.6, <2.0.0
|
||||
six
|
||||
sqlalchemy==1.0.8
|
||||
|
|
@ -2,4 +2,4 @@
|
|||
rm /tmp/dashed_unittests.db
|
||||
export DASHED_CONFIG=tests.dashed_test_config
|
||||
dashed/bin/dashed db upgrade
|
||||
nosetests tests/core_tests.py --with-coverage --cover-package=dashed -v
|
||||
python setup.py nosetests
|
||||
|
|
|
|||
|
|
@ -16,3 +16,9 @@ all_files = 1
|
|||
|
||||
[upload_sphinx]
|
||||
upload-dir = docs/_build/html
|
||||
|
||||
[nosetests]
|
||||
verbosity=1
|
||||
detailed-errors=1
|
||||
with-coverage=1
|
||||
cover-package=dashed
|
||||
|
|
|
|||
3
setup.py
3
setup.py
|
|
@ -30,11 +30,12 @@ setup(
|
|||
'pydruid>=0.2.2, <0.3',
|
||||
'python-dateutil>=2.4.2, <3.0.0',
|
||||
'requests>=2.7.0, <3.0.0',
|
||||
'sqlalchemy-utils>=0.31.3, <0.32.0',
|
||||
'sqlalchemy>=1.0.12, <2.0.0',
|
||||
'sqlalchemy-utils>=0.31.3, <0.32.0',
|
||||
'sqlparse>=0.1.16, <0.2.0',
|
||||
'werkzeug>=0.11.2, <0.12.0',
|
||||
],
|
||||
tests_require=['coverage'],
|
||||
author='Maxime Beauchemin',
|
||||
author_email='maximebeauchemin@gmail.com',
|
||||
url='https://github.com/airbnb/dashed',
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
from panoramix.config import *
|
||||
from dashed.config import *
|
||||
|
||||
AUTH_USER_REGISTRATION_ROLE = 'alpha'
|
||||
SQLALCHEMY_DATABASE_URI = 'sqlite:////tmp/panoramix_unittests.db'
|
||||
|
|
|
|||
Loading…
Reference in New Issue