The qt+= Testlib is added to the QT. Pro file and the console will appear at runtime, just make the following changes to remove
For Qt5.4, the other should be the same.
My Qt is installed on the F drive, open the Qt_lib_testlib.pri file under F:\programs\Qt\Qt5.4.2\5.4\mingw491_32\mkspecs\modules
As follows:
QT.testlib.VERSION = 5.4.2
QT.testlib.MAJOR_VERSION = 5
QT.testlib.MINOR_VERSION = 4
QT.testlib.PATCH_VERSION = 2
QT.testlib.name = Qttest
QT.testlib.libs = $ $QT _module_lib_base
QT.testlib.includes =$ $QT _module_include_base \
$ $QT _module_include_base/qttest
QT.testlib.bins = $ $QT _module_bin_base
QT.testlib.libexecs =$ $QT _module_libexec_base
QT.testlib.plugins =$ $QT _module_plugin_base
QT.testlib.imports =$ $QT _module_import_base
QT.TESTLIB.QML = $ $QT _module_qml_base
QT.testlib.depends = Core
QT.testlib.module_config =
QT.testlib.CONFIG = Console Testlib_defines
QT.testlib.DEFINES = Qt_testlib_lib
Qt_modules + = Testlib
Delete: QT.testlib.CONFIG = save after consoletestlib_defines in console Testlib_defines
Then recompile the program to