def before_all(context): """Setup evolution stuff Being executed once before any test """ try: # Close running evo instances os.system("evolution --force-shutdown > /dev/null") # Skip dogtail actions to print to stdout config.logDebugToStdOut = False config.typingDelay = 0.2 # Include assertion object context.assertion = dummy() # Cleanup existing data before any test cleanup() # Store scenario start time for session logs context.log_start_time = strftime("%Y-%m-%d %H:%M:%S", localtime()) context.app_class = App('evolution') except Exception as e: print("Error in before_all: %s" % e.message)
def before_all(context): """Setup evolution stuff Being executed once before any test """ try: # Close running evo instances os.system("evolution --force-shutdown > /dev/null") # Skip dogtail actions to print to stdout config.logDebugToStdOut = False config.typingDelay = 0.2 # Include assertion object context.assertion = dummy() # Cleanup existing data before any test cleanup() # Store scenario start time for session logs context.log_start_time = strftime("%Y-%m-%d %H:%M:%S", localtime()) context.app_class = App("evolution") except Exception as e: print("Error in before_all: %s" % e.message)
def before_scenario(context, scenario): """ Cleanup previous settings and make sure we have test files in /tmp """ try: cleanup() except Exception as e: print("Error in before_scenario: %s" % e.message)