Skip to content

Fix test_updater_thermal_check_min_max() failure#121

Merged
jleveque merged 1 commit intosonic-net:masterfrom
bratashX:fix_thermalctld_tests
Nov 20, 2020
Merged

Fix test_updater_thermal_check_min_max() failure#121
jleveque merged 1 commit intosonic-net:masterfrom
bratashX:fix_thermalctld_tests

Conversation

@bratashX
Copy link
Contributor

@bratashX bratashX commented Nov 18, 2020

On this PR was changed name generation:

image

and after this changes test_updater_thermal_check_min_max() fails:

01:33:00  ______________________ test_updater_thermal_check_min_max ______________________
01:33:00  
01:33:00      def test_updater_thermal_check_min_max():
01:33:00          chassis = MockChassis()
01:33:00      
01:33:00          thermal = MockThermal()
01:33:00          chassis.get_all_thermals().append(thermal)
01:33:00      
01:33:00          chassis.set_modular_chassis(True)
01:33:00          chassis.set_my_slot(1)
01:33:00          temperature_updater = TemperatureUpdater(SYSLOG_IDENTIFIER, chassis)
01:33:00      
01:33:00          temperature_updater.update()
01:33:00          slot_dict = temperature_updater.chassis_table.get('Thermal 1')
01:33:00  >       assert slot_dict['minimum_temperature'] == str(thermal.get_minimum_recorded())
01:33:00  E       TypeError: 'NoneType' object has no attribute '__getitem__'
01:33:00  
01:33:00  tests/test_thermalctld.py:341: TypeError

Signed-off-by: Petro Bratash [email protected]

@bratashX
Copy link
Contributor Author

bratashX commented Nov 18, 2020

@jleveque @akokhan, please review

@bratashX
Copy link
Contributor Author

bratashX commented Nov 19, 2020

@jleveque, I see that you workaround CI problem, could you please review PR that should fix this issue?

@jleveque
Copy link
Contributor

@bratashX: Thank you for this fix!

@Junchao-Mellanox: Please review.

@jleveque jleveque merged commit f6e5e59 into sonic-net:master Nov 20, 2020
vdahiya12 pushed a commit to vdahiya12/sonic-platform-daemons that referenced this pull request Apr 4, 2022
…t#121)

Add a new function to TlvInfoDecoder which can return device part number as a string.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants