Skip to content

Instantly share code, notes, and snippets.

View danielgran's full-sized avatar
Never give up

Daniel Gran, B. Eng. danielgran

Never give up
View GitHub Profile
@danielgran
danielgran / FiberNode.py
Created October 2, 2024 07:53
Own Fiber Implementation, heavily inspired from the React Project. Converts General and Binaray trees, vice versa. Unit tests ~ 500 LOC
import uuid
class FiberNode:
def __init__(self,
name: str,
child=None,
sibling=None):
self.guid = uuid.uuid4()
self.name = name
@danielgran
danielgran / __init__.py
Created November 23, 2021 05:06
unittest add modules for GitHub action
# put this into your ./test/__init__.py
testdir = os.path.dirname(__file__)
srcdir = '../<your_project_name>' # without <>, remove that comment
sys.path.insert(0, os.path.abspath(os.path.join(testdir, srcdir)))