summaryrefslogtreecommitdiff
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
...
* tests: Add test for bug 766890Bastien Nocera2016-12-192-0/+0
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=766890
* tests: Add rudimentary correctness tests for scalerMartin Guy2016-12-191-0/+288
| | | | | | | | | The scaler's testsuite has no checks for correctness of the scaled image. This add some rudimentary ones, scaling a checkerboard to 1/2 size and seeing if it's all gray and checking the "dest" and "offset" parameters. https://bugzilla.gnome.org/show_bug.cgi?id=80925
* tests: Add test for bug 776105Bastien Nocera2016-12-192-0/+5
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=776105
* tests: Add more pixdata testsBastien Nocera2016-12-163-0/+43
| | | | | | | Those ones should succeed, and we test both uncompressed and RLE-compressed data. https://bugzilla.gnome.org/show_bug.cgi?id=775693
* tests: Fix bug in pixdata testBastien Nocera2016-12-161-1/+1
| | | | | | | | | | In 3724a739 we added a test for the deserializing code, but we shouldn't be free'ing the contents straight away, as gdk_pixdata_deserialize() does not copy the data, but expects it to stay around until we've copied the data to the pixbuf (with gdk_pixbuf_from_pixdata() and copy_pixels == TRUE), or we're done with the pixbuf. https://bugzilla.gnome.org/show_bug.cgi?id=775693
* tests: Additional test for bug 775693Bastien Nocera2016-12-161-0/+4
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=775693
* tests: Add test for bug 775648Bastien Nocera2016-12-131-0/+0
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=775648
* tests: Add test for bug 775242Bastien Nocera2016-12-131-0/+0
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=775242
* tests: Add test for bug 775232Bastien Nocera2016-12-131-0/+0
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=775232
* tests: Add test for bug 775693Bastien Nocera2016-12-133-0/+29
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=775693
* pixdata: Remove pixdata loaderBastien Nocera2016-12-131-3/+3
| | | | | | | | | | | This won't stop pixdata-encoded data from being mmap'ed directly from the binary when using GResource, but will stop external files from being loaded, and thus block a possible attack vector. This also adjusts the new pixdata tests to make sure that external pixdata files fail to load. https://bugzilla.gnome.org/show_bug.cgi?id=776004
* tests: Add separate pixdata testsBastien Nocera2016-12-133-0/+63
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=776004
* tests: Add test case for bug 775218Tobias Mueller2016-12-133-0/+19
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=775218
* tests: Make sure to NULL terminate the arguments passed to g_test_get_filename()Michael Biebl2016-09-081-1/+1
| | | | | | Otherwise the /pixbuf/composite2 test will segfault https://bugzilla.gnome.org/show_bug.cgi?id=771026
* Add a test imageMatthias Clasen2016-08-031-0/+0
|
* bmp: Detect integer overflow of the line widthTobias Mueller2016-08-021-0/+0
| | | | | | | | | | Instead of risking crashes or OOM, return an error if we detect integer overflow. The commit also includes a test image that triggers this overflow when used with pixbuf-read. https://bugzilla.gnome.org/show_bug.cgi?id=768738
* tests: Add tests for new options helpersBastien Nocera2016-08-021-1/+15
| | | | | | Exercising copy_options() and remove_option(). https://bugzilla.gnome.org/show_bug.cgi?id=768043
* ico: Always set errorsHanno Boeck2016-08-021-0/+0
| | | | | | | | | | When the ico header turn out to be bad, always set an error when we fail. Otherwise, applications will get confused. This commit also adds an example image with a bad ico header. https://bugzilla.gnome.org/show_bug.cgi?id=768484
* bmp: Fix an integer overflow in DecodeColormapTobias Mueller2016-08-021-0/+0
| | | | | | | | | | Return an error if n_colors * samples overflows. This commit also adds a reproducer that will cause pixbuf-randomly-modified to crash in the absence of the patch. https://bugzilla.gnome.org/show_bug.cgi?id=768688
* Fix the new test to run as installed testMatthias Clasen2016-06-011-1/+1
|
* Fix bug 766842Daniel Trebbien2016-05-311-2/+90
| | | | | | | | | | | | This commit fixes an issue where pixops_composite_nearest_noscale () had different behavior than pixops_composite_nearest () for pixels in the destination that are not a part of the transformed source image. Per the documentation, the pixels at the edges of the source image should be replicated to infinity. Added a test to tests/pixbuf-composite.c https://bugzilla.gnome.org/show_bug.cgi?id=766842
* tests: Don't run memory-exhausting tests by defaultMatthias Clasen2016-01-301-4/+7
| | | | | | | These tests check for memory overflow in various internal allocations, and require giant amounts of address space. In continuous' vm, they trigger the oom killer. Since this is undesirable, only run the tests in slow mode (ie with -m slow).
* Fix the reftest binaryMatthias Clasen2015-10-261-2/+0
| | | | | | The test was segfaulting here, because of a non-matching signal handler signature. A bit of a mystery how this could succeed on Benjamins system.
* tests: Only install files, not directoriesBenjamin Otte2015-10-131-1/+1
| | | | | Use the *.* glob instead of * to bypass directories and only install files.
* tests: Limit the number of bytes we modify per test to 100Benjamin Otte2015-10-131-2/+4
| | | | | It doesn't make sense to use file_size / 4 because once a file is broken, it's broken. Breaking it even more is not very useful.
* tests: Add a bunch of TGA imagesBenjamin Otte2015-10-137-1/+2
| | | | These images are buggy, but we load them. So add them as reftests.
* tests: Add a bunch of failing TGA imagesBenjamin Otte2015-10-134-0/+0
| | | | They exploit a bunch of bugs I encountered while redoing the TGA loader.
* tests: Add pixbuf-fail testBenjamin Otte2015-10-132-0/+126
| | | | | | | | pixbuf-fail goes into test-images/fail and loads all the images in there, checking that a proper error happens during loading. This is useful for invalid images that cause crashes: Put them in there after they are fixed.
* tests: Move back invalid images that successfully loadBenjamin Otte2015-10-133-0/+0
| | | | I have no idea if they *should* load, but they do.
* tests: Move actually valid image out of fail/ folderBenjamin Otte2015-10-131-0/+0
| | | | | Gimp and gdk-pixbuf load this image, so don't pretend in the testsuite that we can;t load it.
* tests: use g_test_rand_int_range()Benjamin Otte2015-10-131-2/+2
| | | | | ... instead of g_random_int_range() so that the GTest seed machinery actually works.
* tests: Move failing images into seperate directoryBenjamin Otte2015-10-1324-6/+15
|
* tests: Skip reftests for unsupported formatsBenjamin Otte2015-10-133-0/+22
|
* tests: Don't set RLIMIT_ASBenjamin Otte2015-10-131-3/+0
| | | | | When using gio and threads, 64bit code gets unhappy about a limited address space.
* tests: Make add_test_for_all_images() GFile basedBenjamin Otte2015-10-134-39/+141
| | | | | Use that to make pixbuf-reftest accept arguments on the command line to specify a file to test.
* tests: Rename pixbuf-slow-load to pixbuf-reftestBenjamin Otte2015-10-132-7/+7
| | | | I want to use it as a reftesting tool.
* tests: Fix typo in MakefileBenjamin Otte2015-10-1395-1/+1
| | | | | The typo was inconsequential, because the variable was auto-expanded to its current value anyway.
* tests: Implement format_supported() differentlyBenjamin Otte2015-10-131-18/+12
| | | | | | | | | Instead of using strstr (filename, modulename); use has_suffix (filenname, extension_supported_by_module); That way, files can be named .jpg and .jpeg without things going wrong.
* tests: Name test images properlyBenjamin Otte2015-10-1337-15/+15
| | | | | Make sure they have a sane file extension so it's easy for tools to identify them from their filename.
* tests: Remove unsupported imagesBenjamin Otte2015-10-135-3/+0
| | | | The wbmp and ras loaders were dropped, no need to keep the filrs.
* tests: Allow passing a filter function when adding all filesBenjamin Otte2015-10-134-13/+17
| | | | ... and use it to not add reference images.
* tests: Make pixbuf-slow-load test compare imagesBenjamin Otte2015-10-1351-5/+57
| | | | Compare image with a reference PNG.
* test-common: Improve error mesages in pixdata_equal()Benjamin Otte2015-10-131-13/+35
| | | | When something differs, display the actual values
* test-common: Rename function argumentsBenjamin Otte2015-10-133-39/+52
| | | | | Instead of p1 and p2, name the arguments "test" and "ref". This makes the arguments more meaningful and easier to distinguish.
* test-common: If image data differs, output first coords that failBenjamin Otte2015-10-1326-23/+80
|
* tests: Move test imagesBenjamin Otte2015-10-1342-12/+13
| | | | | | Make test-images/ a directory only containing subdirectories for ease of maintenance. Move all images from that directory to test-images/randomly-modified.
* pixbuf-slow-load: Use the new helperMatthias Clasen2015-10-131-59/+6
| | | | | We can use the new helper function here as well, instead of manually listing all the tga test images.
* pixbuf-randomly-modified: Use the new helperMatthias Clasen2015-10-132-15/+11
| | | | | | | Use the new helper function. This fixes the problem that the test previously had with subdirectories in test-images. The helper function will recurse into any subdirectory it finds.
* Add a helper to run tests over directoriesMatthias Clasen2015-10-132-0/+30
| | | | | This helper function recursively runs over a directory and adds a test function for each file in the tree.
* tests: Add TGA testBenjamin Otte2015-10-1346-1/+181
| | | | | | Add a bunch of TGA files and a test that loads the image byte by byte and copies only the parts given via the area-updated signal of the loader and then checks the resulting image is correct.