-
-
Notifications
You must be signed in to change notification settings - Fork 644
Fix copyright detection for bracket notation [C] and [c] #4612
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
base: develop
Are you sure you want to change the base?
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -68,6 +68,16 @@ def test_prepare_text_line_does_not_damage_urls(self): | |
| result = prepare_text_line(cp) | ||
| assert result == 'copyright (c) 2000 World Wide Web Consortium, http://www.w3.org' | ||
|
|
||
| def test_prepare_text_line_normalizes_bracket_C_uppercase(self): | ||
| cp = '[C] The Regents of the University of Michigan and Merit Network, Inc. 1992, 1993, 1994, 1995 All Rights Reserved' | ||
| result = prepare_text_line(cp) | ||
| assert result == '(c) The Regents of the University of Michigan and Merit Network, Inc. 1992, 1993, 1994, 1995 All Rights Reserved' | ||
|
|
||
| def test_prepare_text_line_normalizes_bracket_c_lowercase(self): | ||
| cp = 'Copyright [c] 2023 Example Company' | ||
|
||
| result = prepare_text_line(cp) | ||
| assert result == 'Copyright (c) 2023 Example Company' | ||
|
|
||
| def test_prepare_text_line_does_replace_copyright_signs(self): | ||
| cp = 'Copyright \\A9 1991, 1999 Free Software Foundation, Inc.' | ||
| result = prepare_text_line(cp) | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this comment is not required, the comment above is explanatory and enough. Remove the extra spaces too