<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/t/t4012-diff-binary.sh, branch gitk-resize-error</title>
<subtitle>Fork of git SCM with my patches.</subtitle>
<id>http://git.kilabit.info/git/atom?h=gitk-resize-error</id>
<link rel='self' href='http://git.kilabit.info/git/atom?h=gitk-resize-error'/>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/git/'/>
<updated>2022-01-04T00:24:15Z</updated>
<entry>
<title>Merge branch 'es/test-chain-lint'</title>
<updated>2022-01-04T00:24:15Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2022-01-04T00:24:15Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/git/commit/?id=4f4b18497aea75425506097de7225df8c7cf5c66'/>
<id>urn:sha1:4f4b18497aea75425506097de7225df8c7cf5c66</id>
<content type='text'>
Broken &amp;&amp;-chains in the test scripts have been corrected.

* es/test-chain-lint:
  t6000-t9999: detect and signal failure within loop
  t5000-t5999: detect and signal failure within loop
  t4000-t4999: detect and signal failure within loop
  t0000-t3999: detect and signal failure within loop
  tests: simplify by dropping unnecessary `for` loops
  tests: apply modern idiom for exiting loop upon failure
  tests: apply modern idiom for signaling test failure
  tests: fix broken &amp;&amp;-chains in `{...}` groups
  tests: fix broken &amp;&amp;-chains in `$(...)` command substitutions
  tests: fix broken &amp;&amp;-chains in compound statements
  tests: use test_write_lines() to generate line-oriented output
  tests: simplify construction of large blocks of text
  t9107: use shell parameter expansion to avoid breaking &amp;&amp;-chain
  t6300: make `%(raw:size) --shell` test more robust
  t5516: drop unnecessary subshell and command invocation
  t4202: clarify intent by creating expected content less cleverly
  t1020: avoid aborting entire test script when one test fails
  t1010: fix unnoticed failure on Windows
  t/lib-pager: use sane_unset() to avoid breaking &amp;&amp;-chain
</content>
</entry>
<entry>
<title>t4000-t4999: detect and signal failure within loop</title>
<updated>2021-12-13T18:29:48Z</updated>
<author>
<name>Eric Sunshine</name>
<email>sunshine@sunshineco.com</email>
</author>
<published>2021-12-09T05:11:13Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/git/commit/?id=cbe1d9d630e529d3dd240eacf3d1c9799fef702b'/>
<id>urn:sha1:cbe1d9d630e529d3dd240eacf3d1c9799fef702b</id>
<content type='text'>
Failures within `for` and `while` loops can go unnoticed if not detected
and signaled manually since the loop itself does not abort when a
contained command fails, nor will a failure necessarily be detected when
the loop finishes since the loop returns the exit code of the last
command it ran on the final iteration, which may not be the command
which failed. Therefore, detect and signal failures manually within
loops using the idiom `|| return 1` (or `|| exit 1` within subshells).

Signed-off-by: Eric Sunshine &lt;sunshine@sunshineco.com&gt;
Reviewed-by: Elijah Newren &lt;newren@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>leak tests: mark some diff tests as passing with SANITIZE=leak</title>
<updated>2021-11-01T18:23:08Z</updated>
<author>
<name>Ævar Arnfjörð Bjarmason</name>
<email>avarab@gmail.com</email>
</author>
<published>2021-10-30T22:24:19Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/git/commit/?id=16d4bd4f14e91ab5f70fb74407fc27fc4c8bfe0f'/>
<id>urn:sha1:16d4bd4f14e91ab5f70fb74407fc27fc4c8bfe0f</id>
<content type='text'>
Mark some tests that match "*diff*" as passing when git is compiled
with SANITIZE=leak. They'll now be listed as running under the
"GIT_TEST_PASSING_SANITIZE_LEAK=true" test mode (the "linux-leaks" CI
target).

Signed-off-by: Ævar Arnfjörð Bjarmason &lt;avarab@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>tests: remove most uses of test_i18ncmp</title>
<updated>2021-02-11T07:48:27Z</updated>
<author>
<name>Ævar Arnfjörð Bjarmason</name>
<email>avarab@gmail.com</email>
</author>
<published>2021-02-11T01:53:53Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/git/commit/?id=1108cea7f8ee38a8507c1cc68d1fafe2eb31d623'/>
<id>urn:sha1:1108cea7f8ee38a8507c1cc68d1fafe2eb31d623</id>
<content type='text'>
As a follow-up to d162b25f956 (tests: remove support for
GIT_TEST_GETTEXT_POISON, 2021-01-20) remove most uses of test_i18ncmp
via a simple s/test_i18ncmp/test_cmp/g search-replacement.

I'm leaving t6300-for-each-ref.sh out due to a conflict with in-flight
changes between "master" and "seen", as well as the prerequisite
itself due to other changes between "master" and "next/seen" which add
new test_i18ncmp uses.

Signed-off-by: Ævar Arnfjörð Bjarmason &lt;avarab@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>tests: remove most uses of C_LOCALE_OUTPUT</title>
<updated>2021-02-11T07:48:26Z</updated>
<author>
<name>Ævar Arnfjörð Bjarmason</name>
<email>avarab@gmail.com</email>
</author>
<published>2021-02-11T01:53:51Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/git/commit/?id=a926c4b904bdc339568c2898af955cdc61b31542'/>
<id>urn:sha1:a926c4b904bdc339568c2898af955cdc61b31542</id>
<content type='text'>
As a follow-up to d162b25f956 (tests: remove support for
GIT_TEST_GETTEXT_POISON, 2021-01-20) remove those uses of the now
always true C_LOCALE_OUTPUT prerequisite from those tests which
declare it as an argument to test_expect_{success,failure}.

Signed-off-by: Ævar Arnfjörð Bjarmason &lt;avarab@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>t: use test_might_fail() instead of manipulating exit code manually</title>
<updated>2018-07-03T19:38:04Z</updated>
<author>
<name>Eric Sunshine</name>
<email>sunshine@sunshineco.com</email>
</author>
<published>2018-07-02T00:23:41Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/git/commit/?id=83279748594cf1c7a38ebf518cd6b63cd3d8de37'/>
<id>urn:sha1:83279748594cf1c7a38ebf518cd6b63cd3d8de37</id>
<content type='text'>
These tests manually coerce the exit code of invoked commands to
"success" when they don't care if the command succeeds or fails since
failure of those commands should not cause the test to fail overall.
In doing so, they intentionally break the &amp;&amp;-chain. Modernize by
replacing manual exit code management with test_might_fail() and a
normal &amp;&amp;-chain.

Signed-off-by: Eric Sunshine &lt;sunshine@sunshineco.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>builtin/apply: make parse_single_patch() return -1 on error</title>
<updated>2016-08-11T19:41:46Z</updated>
<author>
<name>Christian Couder</name>
<email>christian.couder@gmail.com</email>
</author>
<published>2016-08-08T21:03:04Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/git/commit/?id=dae197f753c8b3ccdc9c97cfc04f0dbd99a5cc3c'/>
<id>urn:sha1:dae197f753c8b3ccdc9c97cfc04f0dbd99a5cc3c</id>
<content type='text'>
To libify `git apply` functionality we have to signal errors to the
caller instead of die()ing.

To do that in a compatible manner with the rest of the error handling
in builtin/apply.c, parse_single_patch() should return a negative
integer instead of calling die().

Let's do that by using error() and let's adjust the related test
cases accordingly.

Signed-off-by: Christian Couder &lt;chriscool@tuxfamily.org&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>t4012-diff-binary.sh: use the $( ... ) construct for command substitution</title>
<updated>2014-04-30T18:08:05Z</updated>
<author>
<name>Elia Pinto</name>
<email>gitter.spiros@gmail.com</email>
</author>
<published>2014-04-30T16:22:58Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/git/commit/?id=e6ce6f4c7a8bcb2a77e664d0dfc42ee9c2d164d0'/>
<id>urn:sha1:e6ce6f4c7a8bcb2a77e664d0dfc42ee9c2d164d0</id>
<content type='text'>
The Git CodingGuidelines prefer the $(...) construct for command
substitution instead of using the backquotes `...`.

The backquoted form is the traditional method for command
substitution, and is supported by POSIX.  However, all but the
simplest uses become complicated quickly.  In particular, embedded
command substitutions and/or the use of double quotes require
careful escaping with the backslash character.

The patch was generated by:

for _f in $(find . -name "*.sh")
do
   sed -i 's@`\(.*\)`@$(\1)@g' ${_f}
done

and then carefully proof-read.

Signed-off-by: Elia Pinto &lt;gitter.spiros@gmail.com&gt;
Reviewed-by: Matthieu Moy &lt;Matthieu.Moy@imag.fr&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Fix tests under GETTEXT_POISON on git-apply</title>
<updated>2012-08-27T16:26:30Z</updated>
<author>
<name>Jiang Xin</name>
<email>worldhello.net@gmail.com</email>
</author>
<published>2012-08-27T05:36:52Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/git/commit/?id=76638d90e88374f8b1396e4fce75a424260ba6da'/>
<id>urn:sha1:76638d90e88374f8b1396e4fce75a424260ba6da</id>
<content type='text'>
Use the i18n-specific test functions in test scripts for git-apply.
This issue was was introduced in the following commits:

    de373 i18n: apply: mark parseopt strings for translation
    3638e i18n: apply: mark strings for translation

and been broken under GETTEXT_POISON=YesPlease since.

Signed-off-by: Jiang Xin &lt;worldhello.net@gmail.com&gt;
Signed-off-by: Nguyễn Thái Ngọc Duy &lt;pclouds@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>t4012: Use test_must_fail instead of if-else</title>
<updated>2012-07-16T20:51:25Z</updated>
<author>
<name>Alexander Strasser</name>
<email>eclipse7@gmx.net</email>
</author>
<published>2012-07-16T20:47:22Z</published>
<link rel='alternate' type='text/html' href='http://git.kilabit.info/git/commit/?id=c7c0a2503fef1c8746dd4ce074de51fd6b215aa5'/>
<id>urn:sha1:c7c0a2503fef1c8746dd4ce074de51fd6b215aa5</id>
<content type='text'>
Make the code less bulky and easier to read. Also do not overlook
failures like e.g. git failing because of unexpected signals.

Signed-off-by: Alexander Strasser &lt;eclipse7@gmx.net&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
</feed>
