Closed amarquezj closed 3 years ago
Could you share a code that can be used to reproduce the issue?
I also encountered this issue and code from @amarquezj fixed it.
To reproduce this you need __init__.robot
file with suite setup or teardown. listener will try to register those keywords but it will fail since we don;t create suite for __init__
files (which is bug in my opinion).
example__init__.robot
file
*** Settings ***
Suite Setup Keyword
*** Keywords ***
Keyword
No Operation
and test.robot file inside the same directory
*** Test Cases ***
Test
Log stuff
try to run test.robot file with listener
Fixed in #93.
When using an initialization file (
__init__.robot
) for global setups and tear-downs all the keywords/actions performed inside these global setup and teardowns result on error, see below:These happens as there is no suite attached as a parent due to init.robot being an special "test suite" not recognized as a test suite.
These can be fixed by modifying the listener.py file more specifically the start suite method (See below the method code and the fix between commented lines)