Пример #1
0
    def test_get_model(self, duthosts, enum_rand_one_per_hwsku_hostname, localhost, platform_api_conn):
        duthost = duthosts[enum_rand_one_per_hwsku_hostname]
        skip_release_for_platform(duthost, ["202012"], ["arista", "mlnx"])

        for i in self.sfp_setup["sfp_test_port_indices"]:
            model = sfp.get_model(platform_api_conn, i)
            if self.expect(model is not None, "Unable to retrieve transceiver {} model".format(i)):
                self.expect(isinstance(model, STRING_TYPE), "Transceiver {} model appears incorrect".format(i))
        self.assert_expectations()
Пример #2
0
 def test_get_model(self, duthost, localhost, platform_api_conn):
     for i in range(self.num_sfps):
         model = sfp.get_model(platform_api_conn, i)
         if self.expect(
                 model is not None,
                 "Unable to retrieve transceiver {} model".format(i)):
             self.expect(isinstance(model, STRING_TYPE),
                         "Transceiver {} model appears incorrect".format(i))
     self.assert_expectations()
Пример #3
0
 def test_get_model(self, duthosts, enum_rand_one_per_hwsku_hostname,
                    localhost, platform_api_conn):
     for i in self.candidate_sfp:
         model = sfp.get_model(platform_api_conn, i)
         if self.expect(
                 model is not None,
                 "Unable to retrieve transceiver {} model".format(i)):
             self.expect(isinstance(model, STRING_TYPE),
                         "Transceiver {} model appears incorrect".format(i))
     self.assert_expectations()