This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 271178 - Ignored error codes from make test in C++ project
Summary: Ignored error codes from make test in C++ project
Status: NEW
Alias: None
Product: ide
Classification: Unclassified
Component: Code (show other bugs)
Version: 8.2
Hardware: PC Linux
: P3 normal (vote)
Assignee: issues@ide
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-07-27 09:39 UTC by pszemus
Modified: 2017-07-27 09:57 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description pszemus 2017-07-27 09:39:50 UTC
The auto-generated Makefile ignores test programs error (return) codes. That makes executing "make test" useless in Continues Integration environments.


Eg. (nbproject/Makefile-Debug.mk):

# Run Test Targets
.test-conf:
	@if [ "${TEST}" = "" ]; \
	then  \
	    ${TESTDIR}/TestFiles/f1 || true; \
	    ${TESTDIR}/TestFiles/f2 || true; \
	    ${TESTDIR}/TestFiles/f3 || true; \
	else  \
	    ./${TEST} || true; \
	fi


Similar question was asked here: https://stackoverflow.com/questions/24624954/netbeans-generated-makefile-ignores-test-return-codes
Comment 1 pszemus 2017-07-27 09:57:23 UTC
I'd rather see it that way:

.test-conf:
	@if [ "${TEST}" = "" ]; \
	then  \
	    ${TESTDIR}/TestFiles/FileDownloadingBenchmark || exit $?;\
	    ${TESTDIR}/TestFiles/FileDownloadingTest || exit $?;\
	    ${TESTDIR}/TestFiles/GmEngineTest || exit $?;\
	else  \
	    ./${TEST};\
	fi