
from marionette import BaseMarionetteOptions

from greenlight import tests


class ReleaseTestParser(BaseMarionetteOptions):

    def parse_args(self, *args, **kwargs):
        options, test_files = BaseMarionetteOptions.parse_args(self,
                                                               *args, **kwargs)
        if not test_files:
            test_files = [tests.manifest]
        return (options, test_files)


from marionette import BaseMarionetteOptions

from greenlight import tests


class ReleaseTestParser(BaseMarionetteOptions):

    def parse_args(self, *args, **kwargs):
        options, test_files = BaseMarionetteOptions.parse_args(self,
                                                               *args, **kwargs)

        if not any([(k.startswith('log_') and v is not None and '-' in v)
                    for (k, v) in vars(options).items()]):
            options.log_mach = '-'

        if not test_files:
            test_files = [tests.manifest]
        return (options, test_files)

Make colored terminal output the default log formatter.
Make colored terminal output the default log formatter.

  
  from marionette import BaseMarionetteOptions
  
  from greenlight import tests
  
  
  class ReleaseTestParser(BaseMarionetteOptions):
  
      def parse_args(self, *args, **kwargs):
          options, test_files = BaseMarionetteOptions.parse_args(self,
                                                                 *args, **kwargs)
+ 
+         if not any([(k.startswith('log_') and v is not None and '-' in v)
+                     for (k, v) in vars(options).items()]):
+             options.log_mach = '-'
+ 
          if not test_files:
              test_files = [tests.manifest]
          return (options, test_files)
  
Make colored terminal output the default log formatter.
## Code Before:

from marionette import BaseMarionetteOptions

from greenlight import tests


class ReleaseTestParser(BaseMarionetteOptions):

    def parse_args(self, *args, **kwargs):
        options, test_files = BaseMarionetteOptions.parse_args(self,
                                                               *args, **kwargs)
        if not test_files:
            test_files = [tests.manifest]
        return (options, test_files)

## Instruction:
Make colored terminal output the default log formatter.
## Code After:

from marionette import BaseMarionetteOptions

from greenlight import tests


class ReleaseTestParser(BaseMarionetteOptions):

    def parse_args(self, *args, **kwargs):
        options, test_files = BaseMarionetteOptions.parse_args(self,
                                                               *args, **kwargs)

        if not any([(k.startswith('log_') and v is not None and '-' in v)
                    for (k, v) in vars(options).items()]):
            options.log_mach = '-'

        if not test_files:
            test_files = [tests.manifest]
        return (options, test_files)
