def METHOD_NAME(self):
    # get names of files to test
    names = []
    for d in self.test_directories:
        test_dir = os.path.join(basepath, d)
        for n in os.listdir(test_dir):
            if n.endswith('.py') and not n.startswith('bad'):
                names.append(os.path.join(test_dir, n))
    # Test limited subset of files unless the 'cpu' resource is specified.
    if not test.support.is_resource_enabled("cpu"):
        names = random.sample(names, 10)
    for filename in names:
        if test.support.verbose:
            print('Testing %s' % filename)
        source = read_pyfile(filename)
        self.check_roundtrip(source)