No flags found
Use flags to group coverage reports by test type, project and/or folders.
Then setup custom commit statuses and notifications for each flag.
e.g., #unittest #integration
#production #enterprise
#frontend #backend
Use flags to group coverage reports by test type, project and/or folders.
Then setup custom commit statuses and notifications for each flag.
e.g., #unittest #integration
#production #enterprise
#frontend #backend
120 | 120 | def __repr__(self): |
|
121 | 121 | return "%s()" % self.__class__.__name__ |
|
122 | 122 | ||
123 | - | __reduce__ = object.__reduce__ |
|
123 | + | def __reduce__(self): |
|
124 | + | return (self.__class__, tuple()) |
|
124 | 125 | ||
125 | 126 | ||
126 | 127 | #: Convenience constant providing a :class:`tzutc()` instance |
195 | 196 | repr(self._name), |
|
196 | 197 | int(self._offset.total_seconds())) |
|
197 | 198 | ||
198 | - | __reduce__ = object.__reduce__ |
|
199 | + | def __reduce__(self): |
|
200 | + | return (self.__class__, (self._name, self._offset)) |
|
199 | 201 | ||
200 | 202 | ||
201 | 203 | class tzlocal(_tzinfo): |
33 | 33 | dump_kwargs=None, load_kwargs=None): |
|
34 | 34 | """ |
|
35 | 35 | Assert that an object can be pickled and unpickled. This assertion |
|
36 | - | assumes that the desired behavior is that the unpickled object compares |
|
37 | - | equal to the original object, but is not the same object. |
|
36 | + | assumes that the desired behavior is that the unpickled object is the same |
|
37 | + | as the original, when singleton=True. |
|
38 | 38 | """ |
|
39 | 39 | get_nobj = self._get_nobj_file if asfile else self._get_nobj_bytes |
|
40 | 40 | dump_kwargs = dump_kwargs or {} |
|
41 | 41 | load_kwargs = load_kwargs or {} |
|
42 | 42 | ||
43 | 43 | nobj = get_nobj(obj, dump_kwargs, load_kwargs) |
|
44 | - | if not singleton: |
|
44 | + | if singleton: |
|
45 | + | self.assertIs(obj, nobj) |
|
46 | + | else: |
|
45 | 47 | self.assertIsNot(obj, nobj) |
|
46 | 48 | self.assertEqual(obj, nobj) |
|
47 | 49 |
Learn more Showing 32 files with coverage changes found.
dateutil/test/_common.py
dateutil/tz/tz.py
dateutil/zoneinfo/rebuild.py
dateutil/test/test_easter.py
dateutil/test/test_imports.py
dateutil/test/test_isoparser.py
dateutil/zoneinfo/__init__.py
dateutil/test/conftest.py
dateutil/tz/win.py
dateutil/utils.py
dateutil/tz/_factories.py
dateutil/rrule.py
dateutil/parser/_parser.py
dateutil/test/test_internals.py
dateutil/test/test_import_star.py
dateutil/parser/isoparser.py
dateutil/_common.py
dateutil/relativedelta.py
dateutil/parser/__init__.py
dateutil/__init__.py
dateutil/test/test_tz.py
dateutil/easter.py
dateutil/test/property/test_tz_prop.py
dateutil/test/test_relativedelta.py
dateutil/tz/_common.py
dateutil/test/test_utils.py
dateutil/test/test_parser.py
dateutil/test/property/test_isoparse_prop.py
dateutil/test/test_rrule.py
dateutil/tzwin.py
dateutil/tz/__init__.py
dateutil/test/property/test_parser_prop.py
Files | Coverage |
---|---|
dateutil | +<.01% 95.93% |
Project Totals (32 files) | 95.93% |
#1053
b4e9ca9
e5bb4ef
065eae8
e798d1c
c496b4f