Exemplo n.º 1
0
 def test_obj_decode_as_OrderedDict(self):
     v = VyattaJSONParser({}, {})
     node = '{"protocols": null}'
     actual = type(v.decode_vyatta_config(node))
     expected = type(OrderedDict())
     self.assertEqual(actual, expected)
Exemplo n.º 2
0
 def test_null_decode_as_None(self):
     v = VyattaJSONParser({}, {})
     node = '{"protocols": null}'
     actual = v.decode_vyatta_config(node)['protocols']
     expected = None
     self.assertEqual(actual, expected)