

def test_get_environments(self):
    'Should return a list of all chef_environment values found'
    data = chef.get_environments(chef.get_nodes_extended())
    self.assertEqual(len(data), 3)
    expected = [{
        'counts': 1,
        'name': 'none',
    }, {
        'counts': 8,
        'name': 'production',
    }, {
        'counts': 1,
        'name': 'staging',
    }]
    self.assertEqual(data, expected)

dataset/ETHPy150Open edelight/kitchen/kitchen/backends/tests.py TestData.test_get_environments/original