vim / vim

The official Vim repository
https://www.vim.org
Vim License
36.65k stars 5.46k forks source link

src/testdir/test_command_count.in isn't being cleaned by `make {dist}clean` #847

Closed chdiza closed 8 years ago

chdiza commented 8 years ago

Sometime within the last day or so, I noticed that git status is revealing a "modified" file src/testdir/test_command_count.in even after I do make clean. Indeed, it's worse than this, because not even make distclean will get rid of it.

Please make it stop! Test debris should be removed by make clean, and definitely by make distclean.

To observe this behavior:

git clean -fdx
git pull
./configure --blah
make
make test
make clean
git status
brammool commented 8 years ago

chdiza wrote:

Sometime within the last day or so, I noticed that git status is revealing a "modified" file src/testdir/test_command_count.in even after I do make clean. Indeed, it's worse than this, because not even make distclean will get rid of it.

Please make it stop! Test debris should be removed by make clean, and definitely by make distclean.

To observe this behavior:

git clean -fdx
git pull
./configure --blah
make
make test
make clean
git status

Doesn't happen for me, the if was last changed more than a year ago. I can't guess why this happens for you. Perhaps you can break down "make test" in smaller steps to find out what is misbehaving.

Q: What is a patch 22? A: A patch you need to include to make it possible to include patches.

/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \ \ an exciting new programming language -- http://www.Zimbu.org /// \ help me help AIDS victims -- http://ICCF-Holland.org ///

chdiza commented 8 years ago

Perhaps you can break down "make test" in smaller steps

That will take a while. Maybe it will help to note that this is on OS X 10.11.5, and that the configure flags I pass are:

    --disable-gui
    --without-x
    --disable-netbeans
    --disable-nls
chdiza commented 8 years ago

Running git diff yields:

diff --git a/src/testdir/test_command_count.in b/src/testdir/test_command_count.in
index bfde053..4393d8d 100644
--- a/src/testdir/test_command_count.in
+++ b/src/testdir/test_command_count.in
@@ -156,3 +156,6 @@ STARTTEST
 ENDTEST

+aaa: 1 bbb: 1 ccc: 1
+aaa: 1 bbb: 0 ccc: 0
+aaa: 0 bbb: 0 ccc: 0
chdiza commented 8 years ago

I can't reproduce on a fresh clone.

I don't know what happened. I never messed with the tests.

brammool commented 8 years ago

Chdiza wrote:

Running git diff yields:

diff --git a/src/testdir/test_command_count.in b/src/testdir/test_command_count.in
index bfde053..4393d8d 100644
--- a/src/testdir/test_command_count.in
+++ b/src/testdir/test_command_count.in
@@ -156,3 +156,6 @@ STARTTEST
 ENDTEST

+aaa: 1 bbb: 1 ccc: 1
+aaa: 1 bbb: 0 ccc: 0
+aaa: 0 bbb: 0 ccc: 0

Looks like the test fails and writes the input file, instead of writing the output file. Since it works fine for me I can't guess what might cause this problem with your Vim build.

hundred-and-one symptoms of being an internet addict:

  1. You start tilting your head sideways to smile. :-)

    /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \ \ an exciting new programming language -- http://www.Zimbu.org /// \ help me help AIDS victims -- http://ICCF-Holland.org ///

chdiza commented 8 years ago

Come to think of it: I think yesterday or the day before, I accidentally included a -j flag and did make -j4 test. (For building I use make -j4, and for testing I use make test. Absentmindedly I ran make -j4 test.)

That caused me to have to interrupt the test sequence. That may well have corrupted things? If so, maybe the makefile or configure script can check for a -j flag and force it to be 1, or ignore it, just for when the target is test.