Ejemplo n.º 1
0
	def resolveCommand( self ):
		# if no command specified, do not run check
		if not self.getCommand():
			return

		runCommand = RunCommand( [ self.getCommand() ], searchPaths = self.__commandSearchPaths )
		runCommand.checkVersion()
Ejemplo n.º 2
0
	def testCheckCMakeVersion( self ):
		# cmake example
		cmakeCommand = RunCommand( [ "cmake" ] )
		self.assertRaises( ConfigurationError, cmakeCommand.checkVersion, expectedReturnCode = -1 ) # cmake returns 0

		version = cmakeCommand.checkVersion( expectedReturnCode = 0 )
		self.assertTrue( "cmake version" in version )
Ejemplo n.º 3
0
	def testCheckQMakeVersion( self ):
		# qmake example
		qmakeCommand = RunCommand( [ "qmake" ] )
		self.assertRaises( ConfigurationError, qmakeCommand.checkVersion, expectedReturnCode = 1 ) # qmake returns 0

		version = qmakeCommand.checkVersion( expectedReturnCode = 0 )
		self.assertTrue( "QMake version" in version )