Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Accept '?' and '@' in Android source files #335

Merged
merged 1 commit into from
May 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions openformats/formats/android_unescaped.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,6 @@ def _check_unescaped_characters_in_simple_string(text):
not_allowed_unescaped = [
r"(?<!\\)'",
r'(?<!\\)"',
r"(?<!\\)@",
r"(?<!\\)\?",
]
full_pattern = "|".join(not_allowed_unescaped)
if re.search(full_pattern, protected_string):
Expand Down
12 changes: 0 additions & 12 deletions openformats/tests/formats/android/test_android_unescaped.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,15 +75,3 @@ def test_create_string_raises_error(self):
AndroidUnescapedHandler._check_unescaped_characters,
unescaped_string,
)
unescaped_string = "some @ string"
self.assertRaises(
ParseError,
AndroidUnescapedHandler._check_unescaped_characters,
unescaped_string,
)
unescaped_string = "some ? string"
self.assertRaises(
ParseError,
AndroidUnescapedHandler._check_unescaped_characters,
unescaped_string,
)
Loading