예제 #1
0
    def test_plot_income(self):
        '''Plot some incomes for years'''
        directory, filename = os.path.split(os.path.realpath(__file__))
        idc = IncomeDataController(os.path.join(directory, 'countries.csv'),
                os.path.join(directory, "indicator gapminder gdp_per_capita_ppp.xlsx"))
        idc.plot_income(2000)
        idc.plot_income(1990)

        with self.assertRaises(KeyError):
            idc.plot_income(2200)