Skip to content

Commit

Permalink
Merge pull request #45 from phobson/mpl20-py36
Browse files Browse the repository at this point in the history
add python 3.6 to build, new mpl2.0 images
  • Loading branch information
phobson committed Feb 11, 2017
2 parents 31c9537 + 7c22c70 commit e1edaf2
Show file tree
Hide file tree
Showing 15 changed files with 22 additions and 14 deletions.
1 change: 1 addition & 0 deletions .codeclimate.yml
Expand Up @@ -3,4 +3,5 @@ languages:
exclude_paths:
- "docs/*"
- "docs/*/*"
- "paramnormal/tests/*"
- "conda.recipe/*"
3 changes: 3 additions & 0 deletions .travis.yml
Expand Up @@ -6,6 +6,9 @@ matrix:
env:
- COVERAGE=false
- python: 3.5
env:
- COVERAGE=false
- python: 3.6
env:
- COVERAGE=true

Expand Down
8 changes: 7 additions & 1 deletion paramnormal/tests/__init__.py
Expand Up @@ -4,7 +4,13 @@

import paramnormal


def test(*args):
try:
import pytest
except ImportError as e:
raise ImportError("`pytest` is required to run the test suite")

options = [resource_filename('paramnormal', 'tests')]
options.extend(list(args))
return pytest.main(options)
return pytest.main(options)
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
19 changes: 10 additions & 9 deletions paramnormal/tests/test_activity.py
Expand Up @@ -12,6 +12,7 @@


BASELINE_DIR = 'baseline_images/test_activity'
TOLERANCE = 15


def assert_dists_are_equivalent(dist1, dist2):
Expand Down Expand Up @@ -109,7 +110,7 @@ def test_create_normal():
assert_dists_are_equivalent(dist, stats.norm(params.mu, params.sigma))


@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=15)
@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=TOLERANCE)
@seed
def test_plot_pdf_basic():
# first
Expand All @@ -119,7 +120,7 @@ def test_plot_pdf_basic():
return fig


@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=15)
@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=TOLERANCE)
@seed
def test_plot_pdf_fit():
# second
Expand All @@ -132,7 +133,7 @@ def test_plot_pdf_fit():
return fig2


@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=15)
@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=TOLERANCE)
@seed
def test_plot_pdf_xlog():
# first
Expand All @@ -142,7 +143,7 @@ def test_plot_pdf_xlog():
return fig


@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=15)
@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=TOLERANCE)
@seed
def test_plot_cdf_basic():
# first
Expand All @@ -152,7 +153,7 @@ def test_plot_cdf_basic():
return fig


@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=15)
@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=TOLERANCE)
@seed
def test_plot_cdf_fit():
# second
Expand All @@ -165,7 +166,7 @@ def test_plot_cdf_fit():
return fig2


@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=15)
@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=TOLERANCE)
@seed
def test_plot_cdf_xlog():
# first
Expand All @@ -176,7 +177,7 @@ def test_plot_cdf_xlog():
return fig


@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=15)
@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=TOLERANCE)
@seed
def test_plot_sf_basic():
# first
Expand All @@ -186,7 +187,7 @@ def test_plot_sf_basic():
return fig


@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=15)
@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=TOLERANCE)
@seed
def test_plot_sf_fit():
# second
Expand All @@ -199,7 +200,7 @@ def test_plot_sf_fit():
return fig2


@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=15)
@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR, tolerance=TOLERANCE)
@seed
def test_plot_sf_xlog():
# first
Expand Down
4 changes: 0 additions & 4 deletions readme.rst
Expand Up @@ -6,10 +6,6 @@ paramnormal: Conventionally parameterized probability distributions
.. image:: https://coveralls.io/repos/phobson/paramnormal/badge.svg?branch=master&service=github
:target: https://coveralls.io/github/phobson/paramnormal?branch=master

.. image:: https://codeclimate.com/github/phobson/paramnormal/badges/gpa.svg
:target: https://codeclimate.com/github/phobson/paramnormal
:alt: Code Climate


Scipy distributions are weird.
Maybe these will be less weird.
Expand Down
1 change: 1 addition & 0 deletions setup.py
Expand Up @@ -26,6 +26,7 @@
'Topic :: Scientific/Engineering :: Mathematics',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
]
INSTALL_REQUIRES = ['numpy', 'scipy', 'matplotlib']
PACKAGE_DATA = {
Expand Down

0 comments on commit e1edaf2

Please sign in to comment.