summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_dataclasses/__init__.py
Commit message (Collapse)AuthorAgeFilesLines
* gh-118974: Add `decorator` argument to `make_dataclass` (gh-122723)Victorien2024-10-011-0/+17
| | | This is to allow the `dataclasses.make_dataclass` infrastructure to be used with another decorator that's compliant with `typing.dataclass_transform`. The new `decorator` argument to `dataclasses.make_dataclass` is `dataclasses.dataclass`, which used to be hard coded.
* gh-113878: Add `doc` parameter to `dataclasses.field` (gh-114051)sobolevn2024-09-271-3/+22
| | | If using `slots=True`, the `doc` parameter ends up in the `__slots__` dict. The `doc` parameter is also in the corresponding `Field` object.
* gh-89683: add tests for `deepcopy` on frozen dataclasses (gh-123098)Bénédikt Tran2024-09-261-0/+43
| | | Co-authored-by: Eric V. Smith <ericvsmith@users.noreply.github.com>
* gh-90562: Support zero argument super with dataclasses when slots=True ↵Eric V. Smith2024-09-251-1/+125
| | | | | | (gh-124455) Co-authored-by: @wookie184 Co-authored-by: Carl Meyer <carl@oddbird.net>
* gh-123935: Fix typo in `_get_slots` in `dataclasses.py` (#123941)sobolevn2024-09-121-0/+19
|
* gh-91126: Docs and tests for slotted dataclasses with `__init_subclass__` ↵sobolevn2024-09-011-0/+32
| | | | (#123342)
* gh-119180: Add `annotationlib` module to support PEP 649 (#119891)Jelle Zijlstra2024-07-231-0/+10
| | | Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* gh-119260: Clarify is_dataclass Behavior for Subclasses in Documentation and ↵Aditya Borikar2024-05-291-0/+18
| | | | | Tests (#119480) Co-authored-by: Carl Meyer <carl@oddbird.net>
* gh-119581: Add a test of InitVar with name shadowing (#119582)Steven Troxler2024-05-281-0/+23
|
* gh-118033: Fix `__weakref__` not set for generic dataclasses (#118099)Nikita Sobolev2024-05-091-0/+106
|
* gh-116647: Fix recursive child in dataclasses (#116790)et-repositories2024-03-191-0/+9
|
* gh-105866: fix dataclass with slots=True, weakref_slot=True (#105870)Aviel Boag2024-03-191-0/+11
| | | | | Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com> Co-authored-by: Kirill Podoprigora <kirill.bast9@mail.ru> Co-authored-by: Carl Meyer <carl@oddbird.net>
* gh-115285: Fix `test_dataclasses` with `-OO` mode (#115286)Nikita Sobolev2024-02-121-0/+3
|
* gh-109409: Fix inheritance of frozen dataclass from non-frozen dataclass ↵Nikita Sobolev2023-10-121-0/+95
| | | | | | mixins (gh-109437) Fix inheritance of frozen dataclass from non-frozen dataclass mixins
* gh-110273: dataclasses.replace() now raise TypeError for all invalid ↵Serhiy Storchaka2023-10-041-6/+6
| | | | | | | arguments (GH-110274) dataclasses.replace() now raises TypeError instead of ValueError if specify keyword argument for a field declared with init=False or miss keyword argument for required InitVar field.
* gh-108303: Create Lib/test/test_dataclasses/ directory (#108978)Victor Stinner2023-09-061-0/+4547
Move test_dataclasses.py and its "dataclass_*.py" modules into the new Lib/test/test_dataclasses/ subdirectory.