'Tests dict is appended as child to root.'

def test_setter_child_dict(self):

    root = netapp_api.NaElement('root')
    root['d'] = {'e1': 'v1', 'e2': 'v2'}
    e1 = root.get_child_by_name('d')
    self.assertIsInstance(e1, netapp_api.NaElement)
    sub_ch = e1.get_children()
    self.assertEqual(2, len(sub_ch))
    for c in sub_ch:
        self.assertIn(c.get_name(), ['e1', 'e2'])
        if (c.get_name() == 'e1'):
            self.assertEqual('v1', c.get_content())
        else:
            self.assertEqual('v2', c.get_content())
