def test__get_GkWh_2019price2X(self):
        tariff = TariffPrice(self.tariff_id_2x)
        energy = tariff.termPrice(self.items_id_2019_2X, 'GKWh', '€/kWh')

        self.assertEqual(energy, [{
            'period': 'P1',
            'price': 0.116,
            'units': '€/kWh'
        }])
    def test__get_active_energy_2012price2X(self):
        tariff = TariffPrice(self.tariff_id_2x)
        energy = tariff.termPrice(self.items_id_2012_2X, 'ENERGIA', '€/kWh')

        self.assertEqual(energy, [{
            'period': 'P1',
            'price': 0.144722,
            'units': '€/kWh'
        }])
    def test__get_power_2012price2X(self):
        tariff = TariffPrice(self.tariff_id_2x)
        energy = tariff.termPrice(self.items_id_2012_2X, 'POTENCIA',
                                  '€/kW year')

        self.assertEqual(energy, [{
            'period': 'P1',
            'price': 19.893189,
            'units': '€/kW year'
        }])
    def test__get_GkWh_price3X(self):
        tariff = TariffPrice(self.tariff_id_3x)
        energy = tariff.termPrice(self.items_id_2019_3X, 'GKWh', '€/kWh')

        self.assertEqual(energy, [{
            'period': 'P1',
            'price': 0.092,
            'units': '€/kWh'
        }, {
            'period': 'P2',
            'price': 0.081,
            'units': '€/kWh'
        }])
    def test__get_active_energy_price3X(self):
        tariff = TariffPrice(self.tariff_id_3x)
        energy = tariff.termPrice(self.items_id_2019_3X, 'ENERGIA', 'kWh/day')

        self.assertEqual(energy, [
            {
                'period': 'P1',
                'price': 0.121,
                'units': 'kWh/day'
            },
            {
                'period': 'P2',
                'price': 0.105,
                'units': 'kWh/day'
            },
            {
                'period': 'P3',
                'price': 0.079,
                'units': 'kWh/day'
            },
        ])
    def test__get_power_price3X(self):
        tariff = TariffPrice(self.tariff_id_3x)
        energy = tariff.termPrice(self.items_id_2019_3X, 'POTENCIA',
                                  '€/kW year')

        self.assertEqual(energy, [
            {
                'period': 'P1',
                'price': 40.728885,
                'units': '€/kW year'
            },
            {
                'period': 'P2',
                'price': 24.43733,
                'units': '€/kW year'
            },
            {
                'period': 'P3',
                'price': 16.291555,
                'units': '€/kW year'
            },
        ])
    def test__get_GkWh_2012price2X(self):
        tariff = TariffPrice(self.tariff_id_2x)
        energy = tariff.termPrice(self.items_id_2012_2X, 'GKWh', '€/kWh')

        self.assertEqual(energy, [])