Skip to content

Commit

Permalink
added extra horizon test
Browse files Browse the repository at this point in the history
  • Loading branch information
gidden committed Aug 30, 2017
1 parent e79fb6f commit 34f188d
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion tests/test_project.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,13 +137,17 @@ def test_runner_horizon():
runner = Runner(natdata, subdata, Model)
assert [(2010, 2020)] == list(runner.horizon())

df = pd.DataFrame({'a': range(3)}, index=[2010, 2020, 2030])
runner = Runner(df, subdata, Model)
assert [(2010, 2020), (2020, 2030)] == list(runner.horizon())


def test_runner_data():
natdata, subdata = data()
runner = Runner(natdata, subdata, Model)
obs_n, obs_s = runner._data(2010, 2020)
assert_frame_equal(obs_n, natdata)
assert_frame_equal(obs_s, subdata)
assert_frame_equal(obs_s, subdata.sort_index())


def test_runner_update():
Expand Down

0 comments on commit 34f188d

Please sign in to comment.