def test_CursorAlias_reproduce_exception(static_bitmap) -> None: """Testing CursorAlias reproduce method ``FileNotFoundError`` (If cursor alias not created) exception.""" alias = CursorAlias(static_bitmap) with pytest.raises(FileNotFoundError) as excinfo: alias.reproduce() assert str(excinfo.value) == alias_not_exists_err shutil.rmtree(alias.alias_dir)
def win_build(item: Any, alias: CursorAlias) -> None: position = item["position"] size = item["size"] win_key = item["win_key"] canvas_size = item["canvas_size"] win_cfg = alias.reproduce(size, canvas_size, position, delay=3).rename(win_key) WindowsCursor.create(win_cfg, win_out_dir)
def win_build(item: Dict[str, Any], alias: CursorAlias) -> None: position = item["position"] win_size = item["win_size"] win_key = item["win_key"] canvas_size = item["canvas_size"] win_delay = item["win_delay"] win_cfg = alias.reproduce(win_size, canvas_size, position, delay=win_delay).rename(win_key) print(f"Building '{win_cfg.stem}' Windows Cursor...") WindowsCursor.create(win_cfg, win_out_dir)