summaryrefslogtreecommitdiff
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* tests: Improve output of test-shapetest-shape-fixMatthias Clasen2020-11-061-1/+1
| | | | | | | We don't have any test cases for this in our testsuite, but it is useful to run this manually to see the shaping results. The output was missing all but the first char for the last cluster in an item.
* build: Remove deprecated python3 Meson module useEmmanuele Bassi2020-09-303-3/+6
| | | | | | | | | | | | We are using the deprecated python3 module for historical reasons. We used to support both Python 2 and Python 3 in the Autotools build, but since we switched to Meson we *know* we have Python 3 available. This allows us to use a shebang line in the Python scripts we use in the build, instead of invoking them through the Python interpreter in a custom target; Meson knows how to handle shebangs portably as well. This change removes the only deprecation warning coming from Meson when configuring the Pango build.
* Add a test for keycap sequencesfix-keycap-sequencesMatthias Clasen2020-09-172-0/+27
| | | | | This tests that we are not breaking items up in the middle of a keycap sequence.
* Merge branch 'matthiasc/for-master' into 'master'Matthias Clasen2020-09-171-3/+5
|\ | | | | | | | | misc fixes See merge request GNOME/pango!242
| * Make test-layout work for generating data againMatthias Clasen2020-09-171-3/+8
| | | | | | | | This was broken in f6032b754fd76ebbf0ae6.
* | Merge branch 'fix-nested-attributes' into 'master'Matthias Clasen2020-09-171-0/+89
|\ \ | |/ | | | | | | Fix attr iterators with overlapping attributes See merge request GNOME/pango!240
| * Fix attr iterators with overlapping attributesfix-nested-attributesMatthias Clasen2020-09-171-0/+89
| | | | | | | | | | | | | | | | | | | | | | | | | | This broke when PangoAttrIterator was changed to use an array for the stack of current attributes, in dec6c0868ef2c36. We were not always walking the array in the right order. The first attribute to check is at the *end* of the array. This showed up as misrendering in epsilon_0 example in gtk3-demo's text view markup demo. Test included.
* | tests: Fix some more memory errorsasan-fixesMatthias Clasen2020-09-121-5/+15
| | | | | | | | | | test-break was leaking memory in various places, in particular when tests are skipped.
* | tests: Fix memory leaksMatthias Clasen2020-09-123-3/+3
| | | | | | | | These were showing up as errors from lsan.
* | tests: Make test-layout work standaloneMatthias Clasen2020-09-121-0/+3
|/ | | | This broke when I recently reshuffled things.
* Make dependencies to libthai, cairo and xft optional.Niklas Guertler2020-09-091-5/+5
| | | | Added meson features for disabling the dependencies libthai, cairo and xft such that they won't be used even if present on the system. Changed meson dependencies for some tests accordingly.
* Don't assert in pango_language_get_scriptsavoid-script-lang-crashMatthias Clasen2020-09-081-0/+15
| | | | | | | | | | | The assertion in pango_language_get_scripts can actually be triggered since we last regenerated the pango_script_for_lang table. It now includes an entry for und-zsye which has no scripts. Handle this case without asserting. This commit includes a test.
* Undo a recent changeMatthias Clasen2020-08-101-2/+2
| | | | | | Revert 97778b40daedac08f6, since it sadly broke running our testsuite which does pass arguments like -k and --tap.
* test-break: Add a legendMatthias Clasen2020-08-091-4/+19
| | | | | Use test-break --help to get a legend for the codes used in the output.
* test-break: Improve outputMatthias Clasen2020-08-091-3/+3
| | | | | | When we are generating expected output, don't init the tests, so we can avoid the random seed and # in the output.
* tests: Add tests for pango_parse_color_with_alphaMatthias Clasen2020-07-311-40/+74
|
* testsuite: Don't use g_test_skipMatthias Clasen2020-07-304-2/+20
| | | | | | | meson 0.55 considers tests using it to be FAIL. I disagree, but lets quietly skip until 0.55.1 is available.
* Add a reproducer for a pidgin crashMatthias Clasen2020-07-301-0/+20
| | | | This test is reproducing the crash reported in #490.
* Fix a few memory leaks in testsMatthias Clasen2020-07-082-2/+11
| | | | These were pointed out by asan.
* Fix crashes with empty attribute listsMatthias Clasen2020-06-221-0/+51
| | | | | | | | There were a few cases left where empty attribute lists could lead to crashes. This was observed causing crashes in gnumeric. Testcases included.
* Add another attribute list testMatthias Clasen2020-06-171-1/+67
| | | | | This captures the loss of color in the links demo in gtk4-demo with pango 1.45.2
* test-break: Some fixesMatthias Clasen2020-06-111-3/+12
| | | | | | | | Try to make test-break not fail on my system. First I made it skip tests that produce missing glyphs, then I made it call setlocale(). In the end, I needed to just install the right Thai fonts. But these fixes are still useful.
* Add more pango_attr_list_equal testsMatthias Clasen2020-06-111-0/+6
| | | | Check with NULL and empty lists.
* CosmeticsMatthias Clasen2020-06-111-2/+2
|
* Add more attribute testsMatthias Clasen2020-06-101-0/+138
|
* Merge branch 'fix-another-crash' into 'master'Matthias Clasen2020-06-101-0/+14
|\ | | | | | | | | | | | | itemize: Work around gtk2 brokenness Closes #480 See merge request GNOME/pango!198
| * itemize: Work around gtk2 brokennessMatthias Clasen2020-06-101-0/+14
| | | | | | | | | | | | | | | | | | | | | | GTK 2 apparently manages to call pango_itemize_with_base_dir with a non-zero length for a string that contains 0 characters. That in turn causes pango_log2vis_get_embedding_levels to return NULL, and things go downhill from there. A test is included. Fixes: #480
* | Try to make the layout test less sensitiveMatthias Clasen2020-06-102-2/+2
|/ | | | | | Try not to pick a width that makes line-breaking decisions depend on rounding. Lets see if this works better, it makes the test pass locally.
* Revert "tests: Update expected output"Matthias Clasen2020-06-102-0/+2
| | | | This reverts commit 4d8e71471984fb0fc147d1a64695ad5f18576fde.
* tests: Add some tests for pango_attr_list_equalTimm Bäder2020-06-101-0/+71
|
* tests: Add an explanationMatthias Clasen2020-06-091-0/+3
| | | | | Lets explain what this test is about, since it doesn't appear to test anything.
* Add a test for a crash in shape_tabMatthias Clasen2020-06-092-0/+50
| | | | This verifies the fix in the previous commit.
* Merge branch 'wip/baedert/for-master2' into 'master'Matthias Clasen2020-06-084-3/+13
|\ | | | | | | | | Wip/baedert/for master2 See merge request GNOME/pango!190
| * tests: Update expected outputTimm Bäder2020-06-082-2/+0
| | | | | | | | | | We don't set an attribute list in these cases anymore, so reflect that in the output.
| * test-common: Ignore null attr listsTimm Bäder2020-06-081-0/+3
| | | | | | | | | | pango_layout_get_attributes() is explicitly nullable but not every caller handles that case.
| * testattributes: Test iter on empty attr listTimm Bäder2020-06-081-0/+9
| |
| * testattributes: Properly free GStringTimm Bäder2020-06-081-1/+1
| | | | | | | | Not needed afterwards.
* | Merge branch 'for-master' into 'master'Matthias Clasen2020-06-083-19/+74
|\ \ | |/ |/| | | | | For master See merge request GNOME/pango!184
| * tests: Update the locale useEmmanuele Bassi2020-06-083-9/+11
| | | | | | | | | | Create the PangoContext for the test after resetting the locale, and use the en_US.utf8 name, as it seems to be the name used by Fedora.
| * tests: Ensure we respect the TAP output formatEmmanuele Bassi2020-06-083-9/+35
| | | | | | | | | | When dumping the diff between the computed and expected results, we need to respect the TAP format and place "#" in front of each line.
| * Skip test-break when the en_US locale is missingEmmanuele Bassi2020-06-081-3/+12
| | | | | | | | Just like test-layout and test-itemize.
| * Skip test-itemize when the en_US locale is missingEmmanuele Bassi2020-06-081-4/+13
| | | | | | | | Just like test-layout.
| * Skip layout tests if the en_US locale is not availableEmmanuele Bassi2020-06-081-3/+12
| | | | | | | | | | There's no point in running a tests if we know the locale isn't there. The reason gets logged, so the developer can decide to install it.
* | Merge branch 'test-break-no-libthai' into 'master'Matthias Clasen2020-06-081-0/+6
|\ \ | |/ |/| | | | | tests/test-break.c: Only test Thai breaks with libthai available See merge request GNOME/pango!161
| * tests/test-break.c: Only test Thai breaks with libthai availableChun-wei Fan2019-11-251-0/+6
| | | | | | | | | | | | The four.break test data file involves the Thai language, meaning that this test will fail unless we have libthai. Skip this test unless libthai is found.
* | Merge branch 'master' into 'master'Matthias Clasen2020-06-081-1/+1
|\ \ | | | | | | | | | | | | Replace fallthrough comments with G_GNUC_FALLTHROUGH See merge request GNOME/pango!177
| * | Replace fallthrough comments with G_GNUC_FALLTHROUGHTimm Bäder2020-04-141-1/+1
| | |
* | | Merge branch 'unicode13' into 'master'Matthias Clasen2020-06-083-80/+10
|\ \ \ | |/ / |/| | | | | | | | Update Unicode Text Segmentation and Line Breaking to Unicode 13 See merge request GNOME/pango!174
| * | Update break test cases to Unicode 13Peng Wu2020-03-103-80/+10
| |/
* | tests: Use idiomatic Meson and GTest optionsEmmanuele Bassi2020-04-141-6/+10
| | | | | | | | | | | | - Switch to an environment() object, to allow for proper escaping - Use the TAP protocol with GTest - Put all tests under the Pango suite