Exemple #1
0
 def test_splitting_exchanges(self):
     db = [{
         "name":
         "foo",
         "exchanges": [
             {
                 "name": "Absorption chiller 100kW/CH/I U"
             },
             {
                 "name": "Cheese/CH"
             },
         ],
     }]
     result = [{
         "name":
         "foo",
         "exchanges": [
             {
                 "name": "Absorption chiller 100kW",
                 "location": "CH",
                 "simapro name": "Absorption chiller 100kW/CH/I U",
             },
             {
                 "name": "Cheese/CH"
             },
         ],
     }]
     self.assertEqual(split_simapro_name_geo(db), result)
Exemple #2
0
 def test_splitting_datasets(self):
     db = [
         {"name": "Absorption chiller 100kW/CH/I U"},
         {"name": "Cheese/CH"},
     ]
     result = [
         {
             "name": "Absorption chiller 100kW",
             "location": "CH",
             "reference product": "Absorption chiller 100kW",
             "simapro name": "Absorption chiller 100kW/CH/I U",
         },
         {"name": "Cheese/CH"},
     ]
     self.assertEqual(split_simapro_name_geo(db), result)
Exemple #3
0
    def test_splitting_datasets(self):
        db = [
            {'name': 'Absorption chiller 100kW/CH/I U'},
            {'name': 'Cheese/CH'},
        ]
        result = [
            {
                'name': 'Absorption chiller 100kW',
                'location': 'CH',
                'reference product': 'Absorption chiller 100kW',
                'simapro name': 'Absorption chiller 100kW/CH/I U',

            },
            {'name': 'Cheese/CH'},
        ]
        self.assertEqual(split_simapro_name_geo(db), result)
Exemple #4
0
 def test_splitting_exchanges(self):
     db = [{
         'name': 'foo',
         'exchanges': [{
             'name': 'Absorption chiller 100kW/CH/I U'
         }, {
             'name': 'Cheese/CH'
         }],
     }]
     result = [{
         'name': 'foo',
         'exchanges': [{
             'name': 'Absorption chiller 100kW',
             'location': 'CH',
             'simapro name': 'Absorption chiller 100kW/CH/I U',
         }, {
             'name': 'Cheese/CH'
         }],
     }]
     self.assertEqual(split_simapro_name_geo(db), result)