def test_nodeFromTree(sample_xml):
    """Test creating UIElement from XML string"""
    element = UIElement.nodeFromTree(sample_xml)
    assert element is not None
    assert isinstance(element, UIElement)
Test creating UIElement from XML string
tests/test_uielement_osworld.py