mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-10 10:50:10 +00:00
Add a test that dumps settings
This is not much of a test, tbh. But it will give us a convenient dump of all GTK+ settings in continuous, which helps with tracking down test failures that might depend on settings.
This commit is contained in:
parent
434b08fe24
commit
b2e6ad640d
@ -16,24 +16,31 @@ test_simplify = \
|
||||
EXTRA_DIST += \
|
||||
$(test_simplify) \
|
||||
test-simplify.in \
|
||||
test-settings.in \
|
||||
$(NULL)
|
||||
|
||||
TESTS_ENVIRONMENT = \
|
||||
GTK_BUILDER_TOOL="$(top_builddir)/gtk/gtk-builder-tool"
|
||||
GTK_BUILDER_TOOL="$(top_builddir)/gtk/gtk-builder-tool" \
|
||||
GTK_QUERY_SETTINGS="$(top_builddir)/gtk/gtk-query-settings" \
|
||||
$(NULL)
|
||||
|
||||
TEST_PROGS += \
|
||||
test-simplify \
|
||||
test-settings \
|
||||
$(NULL)
|
||||
|
||||
test-simplify:test-simplify.in
|
||||
$(AM_V_GEN) cp $< $@
|
||||
|
||||
test-settings:test-settings.in
|
||||
$(AM_V_GEN) cp $< $@
|
||||
|
||||
if BUILDOPT_INSTALL_TESTS
|
||||
insttestdir = $(libexecdir)/installed-tests/$(PACKAGE)
|
||||
insttest_SCRIPTS = $(TEST_PROGS)
|
||||
nobase_insttest_DATA = $(test_simplify)
|
||||
|
||||
test-simplify.test: test-simplify Makefile
|
||||
%.test: % Makefile
|
||||
$(AM_V_GEN) (echo '[Test]' > $@.tmp; \
|
||||
echo 'Type=session' >> $@.tmp; \
|
||||
echo 'Output=TAP' >> $@.tmp; \
|
||||
@ -43,7 +50,7 @@ test-simplify.test: test-simplify Makefile
|
||||
test_files = $(TEST_PROGS:=.test)
|
||||
|
||||
DISTCLEANFILES = \
|
||||
test-simplify \
|
||||
$(TEST_PROGS) \
|
||||
$(test_files) \
|
||||
$(NULL)
|
||||
|
||||
|
17
testsuite/tools/test-settings.in
Executable file
17
testsuite/tools/test-settings.in
Executable file
@ -0,0 +1,17 @@
|
||||
#! /bin/bash
|
||||
|
||||
GTK_QUERY_SETTINGS=${GTK_QUERY_SETTINGS:-gtk-query-settings}
|
||||
TEST_RESULT_DIR=${TEST_RESULT_DIR:-/tmp}
|
||||
|
||||
shopt -s nullglob
|
||||
|
||||
echo "1..1"
|
||||
|
||||
name=gtk-query-settings
|
||||
result=$TEST_RESULT_DIR/$name.out
|
||||
$GTK_QUERY_SETTINGS 2>/dev/null >$result
|
||||
if [ $(wc -l $result | cut -f1 -d' ') -eq 82 ]; then
|
||||
echo "ok 1 $name"
|
||||
else
|
||||
echo "not ok 1 $name"
|
||||
fi
|
Loading…
Reference in New Issue
Block a user