def opt_coverage(self):
        """
        Generate coverage information in the coverage file in the
        directory specified by the temp-directory option.
        """
        import trace
        self.tracer = trace.Trace(count=1, trace=0)
        sys.settrace(self.tracer.globaltrace)
        self['coverage'] = True

        Generate coverage information in the coverage file in the
        directory specified by the temp-directory option.
        
stackoverflow/venv/lib/python3.6/site-packages/twisted/scripts/trial.py