@@ -599,9 +599,9 @@ def test_structure_default(cs: cstruct, compiled: bool) -> None:
599
599
600
600
assert verify_compiled (cs .test , compiled )
601
601
602
- assert cs .test () == cs .test .default ()
602
+ assert cs .test () == cs .test .__default__ ()
603
603
604
- obj = cs .test .default ()
604
+ obj = cs .test .__default__ ()
605
605
assert obj .t_int == 0
606
606
assert obj .t_int_array == [0 , 0 ]
607
607
assert obj .t_bytesint == 0
@@ -625,11 +625,11 @@ def test_structure_default(cs: cstruct, compiled: bool) -> None:
625
625
for name in obj .fields .keys ():
626
626
assert isinstance (getattr (obj , name ), BaseType )
627
627
628
- assert cs .test_nested () == cs .test_nested .default ()
628
+ assert cs .test_nested () == cs .test_nested .__default__ ()
629
629
630
- obj = cs .test_nested .default ()
631
- assert obj .t_struct == cs .test .default ()
632
- assert obj .t_struct_array == [cs .test .default (), cs .test .default ()]
630
+ obj = cs .test_nested .__default__ ()
631
+ assert obj .t_struct == cs .test .__default__ ()
632
+ assert obj .t_struct_array == [cs .test .__default__ (), cs .test .__default__ ()]
633
633
634
634
assert obj .dumps () == b"\x00 " * 171
635
635
@@ -678,7 +678,7 @@ def test_structure_default_dynamic(cs: cstruct, compiled: bool) -> None:
678
678
679
679
assert verify_compiled (cs .test , compiled )
680
680
681
- assert cs .test () == cs .test .default ()
681
+ assert cs .test () == cs .test .__default__ ()
682
682
683
683
obj = cs .test ()
684
684
assert obj .t_int_array_n == obj .t_int_array_d == []
@@ -694,9 +694,9 @@ def test_structure_default_dynamic(cs: cstruct, compiled: bool) -> None:
694
694
for name in obj .fields .keys ():
695
695
assert isinstance (getattr (obj , name ), BaseType )
696
696
697
- assert cs .test_nested () == cs .test_nested .default ()
697
+ assert cs .test_nested () == cs .test_nested .__default__ ()
698
698
699
- obj = cs .test_nested .default ()
699
+ obj = cs .test_nested .__default__ ()
700
700
assert obj .t_struct_n == obj .t_struct_array_d == []
701
701
702
702
assert obj .dumps () == b"\x00 " * 21
0 commit comments