Netbeans 8.2/Cygwin: Broken pipe error while running CUnit tests

174 views Asked by At

If I create a new C11 application in Netbeans (with auto-generated makefile), add a dummy function to its main.c file that just returns 0, add a test to the function, and run the test via Netbeans from the test folder, I get the following error:

make: *** [nbproject/Makefile-impl.mk:73: .test-impl] Broken pipe

However, when I debug the test, it works properly. I get varying results when testing the whole project-- sometimes the output ends with the following message:

CUnit - A unit testing framework for C - Version 2.1-3
     http://cunit.sourceforge.net/

And sometimes I get the same error. Regardless the actual test results don't get output. Although if I close Netbeans and reopen, the first time I try to test the project the results are displayed correctly, although not any of the subsequent tries.

Any idea what this could be?

This is using CUnit 2.1.3-1, make 4.2.1-2, and gdb 7.12.1-2, all in cygwin 2.10.0 running on Windows 10.

Here's lines 71-73 of the makefile it's referring to, if that helps:

.test-impl: .build-tests-impl .test-pre
    @#echo "=> Running $@... Configuration=$(CONF)"
    "${MAKE}" -f nbproject/Makefile-${CONF}.mk SUBPROJECTS=${SUBPROJECTS} .test-conf

Of course I can provide more of that file if needed, although you should get the same one if you reproduce the steps that led me to the error.

0

There are 0 answers