From e516059c716537259c601c022cc3bad44025385e Mon Sep 17 00:00:00 2001 From: Scott Gasch Date: Thu, 8 Jul 2021 20:08:22 -0700 Subject: [PATCH] Rename simple_acl -> acl --- simple_acl.py => acl.py | 0 dateparse/dateparse_utils.py | 24 ++++++++++++----------- tests/{simple_acl_test.py => acl_test.py} | 2 +- 3 files changed, 14 insertions(+), 12 deletions(-) rename simple_acl.py => acl.py (100%) rename tests/{simple_acl_test.py => acl_test.py} (98%) diff --git a/simple_acl.py b/acl.py similarity index 100% rename from simple_acl.py rename to acl.py diff --git a/dateparse/dateparse_utils.py b/dateparse/dateparse_utils.py index fc5408f..00e7b9d 100755 --- a/dateparse/dateparse_utils.py +++ b/dateparse/dateparse_utils.py @@ -13,13 +13,13 @@ import dateutil.easter import dateutil.tz import pytz +import acl import bootstrap import datetime_utils import decorator_utils from dateparse.dateparse_utilsLexer import dateparse_utilsLexer # type: ignore from dateparse.dateparse_utilsListener import dateparse_utilsListener # type: ignore from dateparse.dateparse_utilsParser import dateparse_utilsParser # type: ignore -import simple_acl as acl logger = logging.getLogger(__name__) @@ -78,16 +78,18 @@ class RaisingErrorListener(antlr4.DiagnosticErrorListener): pass -@decorator_utils.decorate_matching_methods_with(debug_parse, - acl=acl.StringWildcardBasedACL( - allowed_patterns=[ - 'enter*', - 'exit*', - ], - denied_patterns=None, - order_to_check_allow_deny=acl.ACL_ORDER_DENY_ALLOW, - default_answer=False - )) +@decorator_utils.decorate_matching_methods_with( + debug_parse, + acl=acl.StringWildcardBasedACL( + allowed_patterns=[ + 'enter*', + 'exit*', + ], + denied_patterns=None, + order_to_check_allow_deny=acl.ACL_ORDER_DENY_ALLOW, + default_answer=False + ) +) class DateParser(dateparse_utilsListener): PARSE_TYPE_SINGLE_DATE_EXPR = 1 PARSE_TYPE_BASE_AND_OFFSET_EXPR = 2 diff --git a/tests/simple_acl_test.py b/tests/acl_test.py similarity index 98% rename from tests/simple_acl_test.py rename to tests/acl_test.py index 6c9b24c..810aedf 100755 --- a/tests/simple_acl_test.py +++ b/tests/acl_test.py @@ -3,8 +3,8 @@ import re import unittest +import acl import bootstrap -import simple_acl as acl class TestSimpleACL(unittest.TestCase): -- 2.47.1