@pytest.fixture
def keyhint(qtbot, config_stub, key_config_stub):
 config_stub.data = {'colors': {'keyhint.fg': 'white', 'keyhint.fg.suffix': 'yellow', 'keyhint.bg': 'black'}, 'fonts': {'keyhint': 'Comic Sans'}, 'ui': {'keyhint-blacklist': '', 'status-position': 'bottom'}}
 keyhint = KeyHintView(0, None)
 qtbot.add_widget(keyhint)
 assert (keyhint.text() == '')
 return keyhint

@ pytest . fixture def keyhint ( qtbot , config_stub , key_config_stub ) : config_stub . data = { 'colors' : { 'keyhint.fg' : 'white' , 'keyhint.fg.suffix' : 'yellow' , 'keyhint.bg' : 'black' } , 'fonts' : { 'keyhint' : 'Comic Sans' } , 'ui' : { 'keyhint-blacklist' : '' , 'status-position' : 'bottom' } } keyhint = KeyHintView ( 0 , None ) qtbot . add_widget ( keyhint ) assert ( keyhint . text ( ) == '' ) return keyhint
fixture to initialize a keyhintview .