diff --git a/README.md b/README.md index cc4eead..e8735fe 100644 --- a/README.md +++ b/README.md @@ -20,4 +20,4 @@ Resources: ## Legal -Copyright © 2017-2018, Adam Rehn. Licensed under the MIT License, see the file [LICENSE](https://github.com/adamrehn/ue4cli/blob/master/LICENSE) for details. +Copyright © 2017-2018, Adam Rehn. Licensed under the MIT License, see the file [LICENSE](https://github.com/adamrehn/ue4cli/blob/master/LICENSE) for details. diff --git a/setup.py b/setup.py index 672c604..66529d3 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setup( name='ue4cli', - version='0.0.49', + version='0.0.51', description='Command-line interface for Unreal Engine 4', long_description=__readme__, long_description_content_type='text/markdown', diff --git a/ue4cli/UnrealManagerBase.py b/ue4cli/UnrealManagerBase.py index 7aa4d83..6b786b9 100644 --- a/ue4cli/UnrealManagerBase.py +++ b/ue4cli/UnrealManagerBase.py @@ -36,7 +36,9 @@ def setEngineRootOverride(self, rootDir): """ # Set the new root directory - ConfigurationManager.setConfigKey('rootDirOverride', os.path.abspath(rootDir)) + rootDir = os.path.abspath(rootDir) + ConfigurationManager.setConfigKey('rootDirOverride', rootDir) + print('Set engine root path override: {}'.format(rootDir)) # Check that the specified directory is valid and warn the user if it is not try: @@ -451,7 +453,7 @@ def packageDescriptor(self, dir=os.getcwd(), args=[]): else: self.packagePlugin(dir, args) - def runAutomationCommands(self, projectFile, commands, extraArgs, capture=False, enableRHI=False): + def runAutomationCommands(self, projectFile, commands, extraArgs, capture=False, enableRHI=False, disableGameArg=False): ''' Invokes the Automation Test commandlet for the specified project with the supplied automation test commands ''' @@ -467,7 +469,9 @@ def runAutomationCommands(self, projectFile, commands, extraArgs, capture=False, # preventing them from executing correctly. command = '{} {}'.format(Utility.escapePathForShell(self.getEditorBinary(True)), Utility.escapePathForShell(projectFile)) - command += ' -game -buildmachine -stdout -fullstdoutlogoutput -forcelogflush -unattended -nopause -nosplash' + if disableGameArg == False: + command += ' -game' + command += ' -buildmachine -stdout -fullstdoutlogoutput -forcelogflush -unattended -nopause -nosplash' if enableRHI == False: command += ' -nullrhi' command += ' -ExecCmds="automation {};quit" '.format(';'.join(commands)) @@ -510,6 +514,10 @@ def automationTests(self, dir=os.getcwd(), args=[]): enableRHI = len(Utility.findArgs(args, ['--withrhi'])) > 0 args = Utility.stripArgs(args, ['--withrhi']) + # Determine if tests should be run as a game + disableGameArg = len(Utility.findArgs(args, ['--notgame'])) > 0 + args = Utility.stripArgs(args, ['--notgame']) + # Verify that at least one argument was supplied if len(args) == 0: raise RuntimeError('at least one test name must be specified') @@ -552,7 +560,7 @@ def automationTests(self, dir=os.getcwd(), args=[]): # Attempt to run the automation tests Utility.printStderr('Running automation tests...') - logOutput = self.runAutomationCommands(projectFile, command, extraArgs, capture=True, enableRHI=enableRHI) + logOutput = self.runAutomationCommands(projectFile, command, extraArgs, capture=True, enableRHI=enableRHI, disableGameArg=disableGameArg) # Propagate the log output print(logOutput.stdout)