• Benjamin Otte's avatar
    reftests: Add · 363dbb60
    Benjamin Otte authored
    Add a new test runner supposed to do a lot of generic tests. Run it like
    this:
    
    ./gtk-reftest [OPTIONS] TESTFILE [TESTFILES...]
    
    where FILE is a GtkBuilder ui file to run.
    
    For a general test named "test", you want to have the following files:
    1) test.ui
    2) test.ref.ui
    3) test.css (optional)
    The test will then check that test.ui and test.ref.ui are rendered
    identically with the provided css.
    
    In detail, for every provided TESTFILE the test runner will:
    1) Add the css to the default screen
    2) Load the test.ui file and the test.ref.ui file
    3) Grab the first GtkWindow subclass widget
    4) gtk_widget_show() it and take a snapshot image of its contents into
       a cairo surface.
    5) Compare the two images to be bitwise identical. If they are not, a
       diff image will be created hilighting the differences.
    6) Save the images as png files to the output directory named:
       - test.out.png (rendering of test.ui)
       - test.ref.png (rendering of test.ref.ui)
       - test.diff.png (optional, differences from step 5)
    7) Fail the test if the two images are not bitwise identical
    
    Credit for the idea of reftests goes to Mozilla and in particular David
    Baron. For a larger introduction of why reftests are useful, see
    http://weblogs.mozillazine.org/roc/archives/2008/12/reftests.html
    363dbb60
Name
Last commit
Last update
build Loading commit data...
debian Loading commit data...
demos Loading commit data...
docs Loading commit data...
examples Loading commit data...
gdk Loading commit data...
gtk Loading commit data...
m4 Loading commit data...
m4macros Loading commit data...
modules Loading commit data...
perf Loading commit data...
po Loading commit data...
po-properties Loading commit data...
tests Loading commit data...
AUTHORS Loading commit data...
COPYING Loading commit data...
ChangeLog.gtk-async-file-chooser Loading commit data...
ChangeLog.gtk-printing Loading commit data...
ChangeLog.pre-1-0 Loading commit data...
ChangeLog.pre-1-2 Loading commit data...
ChangeLog.pre-2-0 Loading commit data...
ChangeLog.pre-2-10 Loading commit data...
ChangeLog.pre-2-12 Loading commit data...
ChangeLog.pre-2-14 Loading commit data...
ChangeLog.pre-2-16 Loading commit data...
ChangeLog.pre-2-2 Loading commit data...
ChangeLog.pre-2-4 Loading commit data...
ChangeLog.pre-2-6 Loading commit data...
ChangeLog.pre-2-8 Loading commit data...
HACKING Loading commit data...
INSTALL.in Loading commit data...
MAINTAINERS Loading commit data...
Makefile.am Loading commit data...
Makefile.decl Loading commit data...
NEWS Loading commit data...
NEWS.pre-1-0 Loading commit data...
README.commits Loading commit data...
README.in Loading commit data...
README.win32 Loading commit data...
acinclude.m4 Loading commit data...
autogen.sh Loading commit data...
config.h.win32.in Loading commit data...
configure.ac Loading commit data...
gail-3.0-uninstalled.pc.in Loading commit data...
gail-3.0.pc.in Loading commit data...
gdk-3.0.pc.in Loading commit data...
git.mk Loading commit data...
gtk+-3.0-uninstalled.pc.in Loading commit data...
gtk+-3.0.pc.in Loading commit data...
gtk+-unix-print-3.0.pc.in Loading commit data...
gtk+.doap Loading commit data...
gtk+.spec.in Loading commit data...
gtk-engine-check-abi.sh Loading commit data...
gtk-zip.sh.in Loading commit data...
makecopyright Loading commit data...
makefile.msc Loading commit data...
sanitize-la.sh Loading commit data...
sanity_check Loading commit data...