forked from qt-creator/qt-creator
		
	Initially this adds basic gtest testing - to be improved later on. Change-Id: I2121cd24493a8d65c5acd0be5c9dd5858702645d Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
		
			
				
	
	
		
			32 lines
		
	
	
		
			649 B
		
	
	
	
		
			C++
		
	
	
	
	
	
			
		
		
	
	
			32 lines
		
	
	
		
			649 B
		
	
	
	
		
			C++
		
	
	
	
	
	
%{Cpp:LicenseTemplate}\
 | 
						|
@if "%{TestFrameWork}" == "QtTest"
 | 
						|
@if "%{RequireGUI}" == "true"
 | 
						|
%{JS: QtSupport.qtIncludes([ 'QtGui/QApplication' ],
 | 
						|
                           [ 'QtWidgets/QApplication' ]) }\
 | 
						|
@else
 | 
						|
%{JS: QtSupport.qtIncludes([ 'QtCore/QCoreApplication' ],
 | 
						|
                           [ 'QtCore/QCoreApplication' ]) }\
 | 
						|
@endif
 | 
						|
// add necessary includes here
 | 
						|
 | 
						|
int main(int argc, char *argv[])
 | 
						|
{
 | 
						|
@if "%{RequireGUI}" == "true"
 | 
						|
    QApplication a(argc, argv);
 | 
						|
@else
 | 
						|
    QCoreApplication a(argc, argv);
 | 
						|
@endif
 | 
						|
 | 
						|
    return a.exec();
 | 
						|
}
 | 
						|
@else
 | 
						|
#include <iostream>
 | 
						|
 | 
						|
int main(int , char **)
 | 
						|
{
 | 
						|
    std::cout << "Hello World!\\n";
 | 
						|
 | 
						|
    return 0;
 | 
						|
}
 | 
						|
@endif
 |