diff --git a/standardize_test_format/__init__.py b/standardize_test_format/__init__.py index d684b8f..925921c 100644 --- a/standardize_test_format/__init__.py +++ b/standardize_test_format/__init__.py @@ -20,17 +20,16 @@ You may need to call your formatting tool afterwards, as the converter doesn't take formatting into account. """ +import dataclasses import enum import hashlib import re -import dataclasses from ._version import __version__ __all__ = ['__version__', 'standardize_java_text', 'NamingScheme', 'Config'] - class NamingScheme(enum.Enum): PRESERVE = 'preserve' HASH_OF_DESC = 'hash' diff --git a/standardize_test_format/__main__.py b/standardize_test_format/__main__.py index c55281d..23693e3 100644 --- a/standardize_test_format/__main__.py +++ b/standardize_test_format/__main__.py @@ -1,7 +1,7 @@ import argparse import pathlib -from . import NamingScheme, standardize_java_text, Config +from . import Config, NamingScheme, standardize_java_text def test_files(repo: pathlib.Path) -> list[pathlib.Path]: @@ -34,10 +34,26 @@ def argument_parser(): argparser = argparse.ArgumentParser() argparser.add_argument('repo', type=pathlib.Path, help='Repository') argparser.add_argument('-i', action='store_true', help='Write to files') - argparser.add_argument('--javadoc', action='store_true', help='Generate Javadoc for tests') - argparser.add_argument('--displayname', action='store_true', help='Generate DisplayName for tests') - argparser.add_argument('--only-javadoc', action='store_true', help='Only change tests with an existing Javadoc') - argparser.add_argument('--only-displayname', action='store_true', help='Only change test with an existing DisplayName') + argparser.add_argument( + '--javadoc', + action='store_true', + help='Generate Javadoc for tests', + ) + argparser.add_argument( + '--displayname', + action='store_true', + help='Generate DisplayName for tests', + ) + argparser.add_argument( + '--only-javadoc', + action='store_true', + help='Only change tests with an existing Javadoc', + ) + argparser.add_argument( + '--only-displayname', + action='store_true', + help='Only change test with an existing DisplayName', + ) argparser.add_argument( '--naming', type=NamingScheme,