import pandas

from sharepa.helpers import pretty_print
from sharepa.helpers import source_counts


def test_pretty_print():
    some_stuff = '{"Dusty": "Rhodes"}'
    pretty_print(some_stuff)


def test_source_counts():
    all_counts = source_counts()
    assert isinstance(all_counts, pandas.core.frame.DataFrame)

import vcr
import pandas
import pytest

from sharepa.search import ShareSearch
from sharepa.helpers import pretty_print
from sharepa.helpers import source_counts


@vcr.use_cassette('tests/vcr/simple_execute.yaml')
def test_pretty_print():
    my_search = ShareSearch()
    result = my_search.execute()
    the_dict = result.to_dict()
    try:
        pretty_print(the_dict)
    except:
        pytest.fail("Unexpected exception!!")


def test_source_counts():
    all_counts = source_counts()
    assert isinstance(all_counts, pandas.core.frame.DataFrame)

Add pytest fail check on raising pretty print exeption
Add pytest fail check on raising pretty print exeption
