Issue #23883: Add missing APIs to calendar.__all__
Patch by Joel Taddei and Jacek Kołodziej.
This commit is contained in:
parent
7978e10441
commit
4eb376c441
|
@ -12,7 +12,9 @@ import locale as _locale
|
|||
__all__ = ["IllegalMonthError", "IllegalWeekdayError", "setfirstweekday",
|
||||
"firstweekday", "isleap", "leapdays", "weekday", "monthrange",
|
||||
"monthcalendar", "prmonth", "month", "prcal", "calendar",
|
||||
"timegm", "month_name", "month_abbr", "day_name", "day_abbr"]
|
||||
"timegm", "month_name", "month_abbr", "day_name", "day_abbr",
|
||||
"Calendar", "TextCalendar", "HTMLCalendar", "LocaleTextCalendar",
|
||||
"LocaleHTMLCalendar", "weekheader"]
|
||||
|
||||
# Exception raised for bad input (with string parameter for details)
|
||||
error = ValueError
|
||||
|
|
|
@ -815,5 +815,14 @@ class CommandLineTestCase(unittest.TestCase):
|
|||
b'href="custom.css" />', stdout)
|
||||
|
||||
|
||||
class MiscTestCase(unittest.TestCase):
|
||||
def test__all__(self):
|
||||
blacklist = {'error', 'mdays', 'January', 'February', 'EPOCH',
|
||||
'MONDAY', 'TUESDAY', 'WEDNESDAY', 'THURSDAY', 'FRIDAY',
|
||||
'SATURDAY', 'SUNDAY', 'different_locale', 'c',
|
||||
'prweek', 'week', 'format', 'formatstring', 'main'}
|
||||
support.check__all__(self, calendar, blacklist=blacklist)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
unittest.main()
|
||||
|
|
Loading…
Reference in New Issue