Skip to content

Commit

Permalink
improve unit tests, bump version to 0.3.4
Browse files Browse the repository at this point in the history
  • Loading branch information
mortada committed Mar 3, 2015
1 parent 9b21cf9 commit 1785968
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion fredapi/__init__.py
@@ -1,3 +1,3 @@

__version__ = '0.3.3'
__version__ = '0.3.4'
from fredapi.fred import Fred
8 changes: 8 additions & 0 deletions fredapi/tests/test_fred.py
@@ -1,6 +1,7 @@

import unittest
from fredapi import Fred
from datetime import datetime


class TestFred(unittest.TestCase):
Expand All @@ -27,5 +28,12 @@ def testGetSeries(self):
except ValueError:
pass

def testSearch(self):
personal_income_series = self.fred.search_by_release(175, limit=5, order_by='popularity', sort_order='desc')
series_ids = ['PCPI08081', 'PCPI22071', 'PCPI42101', 'PCPI06083', 'PCPI06075']
for series_id in series_ids:
self.assertTrue(series_id in personal_income_series.index)
self.assertEqual(personal_income_series.ix[series_id, 'observation_start'], datetime(1969, 1, 1))

def tearDown(self):
return

0 comments on commit 1785968

Please sign in to comment.