Skip to content

tests/eas/rfc: Only use the energy meter if the platform supports it

Darryl Green requested to merge github/fork/JaviMerino/fix_rfc_emeter into master

Created by: JaviMerino

EnergyMeter.getInstance() returns None if there is no energy meter for the platform. Therefore, env.emeter is None for platforms that don't have an energy meter and rfc.py fails with an AttributeError when it tries to do things like cls.env.emeter.reset()

Check that emeter is not None before calling any of its methods.

Merge request reports