git/list[1] front-page[2] threads[3] people[4] search[5] about
 

make test

From
Joachim Schmitz <jojo@schmitz-digital.de>
Date
Oct 15, 2012, 10:36 UTC
Message-ID
<k5gov5$fe1$1@ger.gmane.org>
Hi folks

I'm trying to understand why certain tests in 'make test' fail. Here's the first one

$ ../git --version git version 1.8.0.rc2.5.g6b89306 $ GIT_TEST_CMP_USE_COPIED_CONTEXT=true ./t0000-basic.sh # our diff doesn't understand -u ok 1 - .git/objects should be empty after git init in an empty repo ... ok 3 - success is reported like this not ok 4 - pretend we have a known breakage # TODO known breakage

    This is expected, right?

ok 5 - pretend we have fixed a known breakage (run in sub test-lib) ... ok 11 - tests clean up after themselves

    the next is not though? Why might it be failing, where to check?

not ok - 12 tests clean up even on failures # # mkdir failing-cleanup && # ( # cd failing-cleanup && # # cat >failing-cleanup.sh <<-EOF && # #!/bin/sh # # test_description='Failing tests with cleanup commands' # # # Point to the t/test-lib.sh, which isn't in ../ as usual # TEST_DIRECTORY="/home/jojo/git/git/t" # . "$TEST_DIRECTORY"/test-lib.sh # # test_expect_success 'tests clean up even after a failure' ' # touch clean-after-failure && # test_when_finished rm clean-after-failure && # (exit 1) # ' # test_expect_success 'failure to clean up causes the test to fail' ' # test_when_finished "(exit 2)" # ' # test_done # # EOF # # chmod +x failing-cleanup.sh && # test_must_fail ./failing-cleanup.sh >out 2>err && # ! test -s err && # ! test -f "trash directory.failing-cleanup/clean-after-failure" && # sed -e 's/Z$//' -e 's/^> //' >expect <<-\EOF && # > not ok - 1 tests clean up even after a failure # > # Z # > # touch clean-after-failure && # > # test_when_finished rm clean-after-failure && # > # (exit 1) # > # Z # > not ok - 2 failure to clean up causes the test to fail # > # Z # > # test_when_finished "(exit 2)" # > # Z # > # failed 2 among 2 test(s) # > 1..2 # EOF # test_cmp expect out # ) # ok 13 - git update-index without --add should fail adding ... ok 47 - very long name in the index handled sanely # still have 1 known breakage(s) # failed 1 among remaining 46 test(s) 1..47

Bye, Jojo 
Next: Johannes Sixt
Message 1 of 12 in “make test”
  1. Joachim SchmitzOct 15, 2012
  2. Johannes SixtOct 15, 2012
  3. Joachim SchmitzOct 15, 2012
  4. Johannes SixtOct 15, 2012
  5. Joachim SchmitzOct 15, 2012
  6. Johannes SixtOct 15, 2012
  7. Joachim SchmitzOct 15, 2012
  8. Johannes SixtOct 15, 2012
  9. Andreas SchwabOct 15, 2012
  10. Joachim SchmitzOct 15, 2012
  11. Joachim SchmitzOct 17, 2012
  12. Joachim SchmitzOct 15, 2012

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.