diff options
author | Jean Felder <jfelder@src.gnome.org> | 2020-04-27 21:36:26 +0200 |
---|---|---|
committer | Jean Felder <jfelder@src.gnome.org> | 2020-12-06 15:04:45 +0100 |
commit | 1df10f76c4fe2b97bb7982e8278ef86828c7b6ba (patch) | |
tree | 847517e434802f3363f21199736c82722b28a815 /tests | |
parent | 66fd10e5b97e0e29d969edfb1cfdc0eed4bfe090 (diff) | |
download | pygobject-1df10f76c4fe2b97bb7982e8278ef86828c7b6ba.tar.gz |
tests: Do not use the margin property for template tests
In GTK4, the margin property does not exist anymore. Replace it by the
margin-top property.
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test_gtk_template.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/test_gtk_template.py b/tests/test_gtk_template.py index ec737fed..9699cc7e 100644 --- a/tests/test_gtk_template.py +++ b/tests/test_gtk_template.py @@ -537,7 +537,7 @@ def test_internal_child(): <template class="{0}" parent="GtkBox"> <child> <object class="GtkBox" id="somechild"> - <property name="margin">42</property> + <property name="margin-top">42</property> </object> </child> </template> @@ -551,7 +551,7 @@ def test_internal_child(): somechild = Gtk.Template.Child(internal=True) thing = MainThing() - assert thing.somechild.props.margin == 42 + assert thing.somechild.props.margin_top == 42 other_type_name = new_gtype_name() @@ -562,7 +562,7 @@ def test_internal_child(): <object class="{1}"> <child internal-child="somechild"> <object class="GtkBox"> - <property name="margin">24</property> + <property name="margin-top">24</property> <child> <object class="GtkLabel"> <property name="label">foo</property> @@ -585,7 +585,7 @@ def test_internal_child(): assert isinstance(child, MainThing) child = child.get_children()[0] assert isinstance(child, Gtk.Box) - assert child.props.margin == 24 + assert child.props.margin_top == 24 child = child.get_children()[0] assert isinstance(child, Gtk.Label) assert child.props.label == "foo" |