test: log all function calls to interfaces

Makes debugging easier to see exactly who's being called.
This commit is contained in:
Peter Hutterer 2023-03-02 13:37:57 +10:00
parent 59542a1ba0
commit 3c589f1b20

View file

@ -246,7 +246,9 @@ class {{interface.camel_name}}(Interface):
{% for outgoing in interface.outgoing %}
def {{outgoing.camel_name}}(self{%- for arg in outgoing.arguments %}, {{arg.name}}: {{arg.signature}}{% endfor -%}) -> bytes:
return self.format({%- for arg in outgoing.arguments %}{{arg.name}}, {% endfor -%}opcode={{outgoing.opcode}}, signature="{{outgoing.signature}}")
data = self.format({%- for arg in outgoing.arguments %}{{arg.name}}, {% endfor -%}opcode={{outgoing.opcode}}, signature="{{outgoing.signature}}")
logger.debug("composing message", oject=self, func="{{interface.name}}.{{outgoing.name}}", args={ {%- for arg in outgoing.arguments %}"{{arg.name}}": {{arg.name}}, {% endfor -%} }, result=hexlify(data))
return data
{% endfor %}
{% for incoming in interface.incoming %}