Skip to content

Commit fe5ae9c

Browse files
committed
fix test_dont_modify_parent_inplace -> bug?
1 parent 9a004d4 commit fe5ae9c

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

xarray/tests/test_datatree.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,9 @@ def test_bad_names(self):
3737
class TestFamilyTree:
3838
def test_dont_modify_parent_inplace(self):
3939
# GH issue 9196
40-
root: DataTree = DataTree()
41-
DataTree(name="child", parent=root)
40+
root: DataTree = DataTree(name="root")
41+
child: DataTree = DataTree(name="child")
42+
child.parent = root
4243
assert root.children == {}
4344

4445
def test_dont_modify_children_inplace(self):

0 commit comments

Comments
 (0)