예제 #1
0
    def test_show_ip_ospf_virtual_links_full1(self):
        super().test_show_ip_ospf_virtual_links_full1()
        
        self.maxDiff = None

        def mapper(key):
            return self.outputs[key]

        self.device.execute = Mock()
        self.device.execute.side_effect = mapper
        
        obj = ShowIpOspfVirtualLinks(device=self.device)
        parsed_output = obj.parse()
        self.assertEqual(parsed_output, self.golden_parsed_output1)
예제 #2
0
 def test_show_ip_ospf_sham_links_empty(self):
     self.maxDiff = None
     self.device = Mock(**self.empty_output)
     obj = ShowIpOspfVirtualLinks(device=self.device)
     with self.assertRaises(SchemaEmptyParserError):
         parsed_output = obj.parse()