Python unittest.util() Examples

The following are 2 code examples of unittest.util(). You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may also want to check out all available functions/classes of the module unittest , or try the search function .
Example #1
Source File: test_main.py    From marbles with MIT License 5 votes vote down vote up
def __str__(self):  # noqa: D102
        params = ', '.join('{}={!r}'.format(name, getattr(self, name))
                           for name in ('runner', 'verbose', 'test_file'))
        return '{} ({}) ({})'.format(
            self._testMethodName,
            unittest.util.strclass(self.__class__),
            params) 
Example #2
Source File: test_log.py    From marbles with MIT License 5 votes vote down vote up
def __str__(self):
        params = ', '.join(
            '{}={!r}'.format(name, getattr(self, '_{}'.format(name)))
            for name in ('use_env', 'use_file', 'use_annotated_test_case'))
        return '{} ({}) ({})'.format(
            self._testMethodName,
            unittest.util.strclass(self.__class__),
            params)