From 9d2c3f5e68208576eea82fa313a38689bf16ba56 Mon Sep 17 00:00:00 2001 From: Benjamin Otte Date: Thu, 14 Aug 2014 19:52:33 +0200 Subject: [PATCH] reftests: Add reftest for statusbar fix https://bugzilla.gnome.org/show_bug.cgi?id=724281 --- testsuite/reftests/Makefile.am | 5 +++- testsuite/reftests/statusbar-remove-all.c | 27 +++++++++++++++++++ .../reftests/statusbar-remove-all.ref.ui | 22 +++++++++++++++ testsuite/reftests/statusbar-remove-all.ui | 23 ++++++++++++++++ 4 files changed, 76 insertions(+), 1 deletion(-) create mode 100644 testsuite/reftests/statusbar-remove-all.c create mode 100644 testsuite/reftests/statusbar-remove-all.ref.ui create mode 100644 testsuite/reftests/statusbar-remove-all.ui diff --git a/testsuite/reftests/Makefile.am b/testsuite/reftests/Makefile.am index 9e04237682..336a507c48 100644 --- a/testsuite/reftests/Makefile.am +++ b/testsuite/reftests/Makefile.am @@ -346,6 +346,8 @@ testdata = \ sizegroups-evolution-identity-page.ref.ui \ sizegroups-get-preferred-null.ui \ sizegroups-get-preferred-null.ref.ui \ + statusbar-remove-all.ref.ui \ + statusbar-remove-all.ui \ style-properties-nth-child.css \ style-properties-nth-child.ref.ui \ style-properties-nth-child.ui \ @@ -402,8 +404,9 @@ libreftest_la_LDFLAGS = -rpath $(reftestdir) -avoid-version -module $(no_undefin libreftest_la_CFLAGS = $(gtk_reftest_CFLAGS) libreftest_la_LIBADD = $(gtk_reftest_LDADD) libreftest_la_SOURCES = \ - set-default-direction.c \ expand-expander.c \ + set-default-direction.c \ + statusbar-remove-all.c \ textview-border-windows.c \ $(NULL) diff --git a/testsuite/reftests/statusbar-remove-all.c b/testsuite/reftests/statusbar-remove-all.c new file mode 100644 index 0000000000..6960fd1625 --- /dev/null +++ b/testsuite/reftests/statusbar-remove-all.c @@ -0,0 +1,27 @@ +/* + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library. If not, see . + */ + +#include "config.h" + +#include + + +G_MODULE_EXPORT void +statusbar_remove_all (GtkStatusbar *s) +{ + gtk_statusbar_push (s, 0, "One"); + gtk_statusbar_push (s, 0, "Two"); + gtk_statusbar_remove_all (s, 0); +} diff --git a/testsuite/reftests/statusbar-remove-all.ref.ui b/testsuite/reftests/statusbar-remove-all.ref.ui new file mode 100644 index 0000000000..c42d2ff143 --- /dev/null +++ b/testsuite/reftests/statusbar-remove-all.ref.ui @@ -0,0 +1,22 @@ + + + + + + False + popup + + + True + False + 10 + 10 + 10 + 10 + 6 + 6 + 2 + + + + diff --git a/testsuite/reftests/statusbar-remove-all.ui b/testsuite/reftests/statusbar-remove-all.ui new file mode 100644 index 0000000000..21a33d2bcb --- /dev/null +++ b/testsuite/reftests/statusbar-remove-all.ui @@ -0,0 +1,23 @@ + + + + + + False + popup + + + True + False + 10 + 10 + 10 + 10 + 6 + 6 + 2 + + + + +