Fix build against libyaml 0.2.5. Taken from upstream: https://github.com/tlsa/libcyaml/commit/0e947264b947f51f7ea785068637c4bfce5d4171 diff --git a/test/units/save.c b/test/units/save.c --- a/test/units/save.c +++ b/test/units/save.c @@ -3476,7 +3476,7 @@ static bool test_save_sequence_null_values_int( ttest_report_ctx_t *report, const cyaml_config_t *config) { - static const unsigned char ref[] = + static const unsigned char ref1[] = "---\n" "- 7\n" "- 6\n" @@ -3487,6 +3487,18 @@ static bool test_save_sequence_null_values_int( "- \n" "- 0\n" "...\n"; + /* As of libyaml 0.2.5, trailing spaces are not emitted. */ + static const unsigned char ref2[] = + "---\n" + "- 7\n" + "- 6\n" + "- 5\n" + "-\n" + "- 3\n" + "- 2\n" + "-\n" + "- 0\n" + "...\n"; static const int d[] = { 7, 6, 5, 4, 3, 2, 1, 0 }; static const int *data[] = { d + 0, d + 1, d + 2, NULL, d + 4, d + 5, NULL, d + 7, }; @@ -3515,11 +3527,12 @@ static bool test_save_sequence_null_values_int( return ttest_fail(&tc, cyaml_strerror(err)); } - if (len != YAML_LEN(ref) || memcmp(ref, buffer, len) != 0) { + if ((len != YAML_LEN(ref1) || memcmp(ref1, buffer, len) != 0) && + (len != YAML_LEN(ref2) || memcmp(ref2, buffer, len) != 0)) { return ttest_fail(&tc, "Bad data:\n" "EXPECTED (%zu):\n\n%.*s\n\n" "GOT (%zu):\n\n%.*s\n", - YAML_LEN(ref), YAML_LEN(ref), ref, + YAML_LEN(ref1), YAML_LEN(ref1), ref1, len, len, buffer); }
path: root/gnu/packages/toys.scm
AgeCommit message (Expand)Author
2023-05-24gnu: lolcat: Update to 1.4....* gnu/packages/toys.scm (lolcat): Update to 1.4. [version]: Switch to release tag. [arguments]: Use G-expressions. Remove trailing #t. <#:phases>: Replace assoc-ref with #$output. Signed-off-by: 宋文武 <iyzsong@member.fsf.org> kiasoc5
2022-08-28gnu: Add fortunes-jkirchartz....* gnu/packages/toys.scm (fortunes-jkirchartz): New variable. Liliana Marie Prikler
2022-08-28gnu: Add daikichi....* gnu/packages/toys.scm (daikichi): New variable. Liliana Marie Prikler
2022-07-17gnu: lolcat: Move to (gnu packages toys)....As fun as this is, the gameplay is disappointing. Also add a missing 2019 copyright for Liliana Marie. * gnu/packages/games.scm (lolcat): Move from here… * gnu/packages/toys.scm (lolcat): …to here. Tobias Geerinckx-Rice
2022-06-05gnu: oneko: Edit description....* gnu/packages/toys.scm (oneko)[description]: Use full sentences. Name the only two species of animated character actually available. Add an unfortunate note about Wayland. Tobias Geerinckx-Rice
2022-06-05gnu: oneko: Remove trailing #t from phases....* gnu/packages/toys.scm (oneko)[source]: Don't explicitly return #t from snippet… [arguments]: …nor from phases. Tobias Geerinckx-Rice
2022-01-02gnu: xsnow: Simplify inputs....* gnu/packages/toys.scm (xsnow)[inputs]: Remove labels. Signed-off-by: Leo Famulari <leo@famulari.name> kiasoc5
2022-01-02gnu: xsnow: Update to 3.4.2....* gnu/packages/toys.scm (xsnow): Update to 3.4.2. [source, home-page]: Update URLs. Signed-off-by: Leo Famulari <leo@famulari.name> kiasoc5
2021-12-13gnu: Simplify package inputs....This commit was obtained by running: ./pre-inst-env guix style without any additional argument. Ludovic Courtès