def test_get_operation_names(self): assert len(get_operation_names()) > 0
def print_operations_list(): operation_names = sorted(get_operation_names()) print_groups_by_comparison( operation_names, comparator=lambda item: item.split('.')[0], )
if WRITE_EMPTIES: makedirs(fact_folder) f = open(fact_file, 'w') f.write(EMPTY_FACT) f.close() print(' {0}: {1}'.format( 'written' if WRITE_EMPTIES else 'missing', fact_file, )) print() print('--> {0} empty operation tests'.format( 'Generating' if WRITE_EMPTIES else 'Printing', )) for operation in get_operation_names(): if WRITE_LIMIT and operation not in WRITE_LIMIT: continue operation_folder = path.join('tests', 'operations', operation) if not path.exists(operation_folder): operation_file = path.join(operation_folder, 'empty.json') if WRITE_EMPTIES: makedirs(operation_folder) f = open(operation_file, 'w') f.write(EMPTY_OPERATION) f.close() print(' {0}: {1}'.format( 'written' if WRITE_EMPTIES else 'missing',