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

Add tests to verify the behavior of _ctypes.CopyComPointer. #127183

Closed
junkmd opened this issue Nov 23, 2024 · 0 comments
Closed

Add tests to verify the behavior of _ctypes.CopyComPointer. #127183

junkmd opened this issue Nov 23, 2024 · 0 comments
Labels
tests Tests in the Lib/test dir topic-ctypes type-feature A feature request or enhancement

Comments

@junkmd
Copy link
Contributor

junkmd commented Nov 23, 2024

Feature or enhancement

Proposal:

There are other untested features related to COM besides COMError.

_ctypes.CopyComPointer, as the name suggests, copies a COM pointer from src to dst.
It also manages reference counts before and after the copy.

In the future, this functionality may also need to be made public similar to COMError.
However, my plan is to first add tests to confirm its current behavior, and then consider making it public and adding documentation.

Has this already been discussed elsewhere?

No response given

Links to previous discussion of this feature:

No response

Linked PRs

@junkmd junkmd added the type-feature A feature request or enhancement label Nov 23, 2024
@picnixz picnixz added tests Tests in the Lib/test dir topic-ctypes labels Nov 23, 2024
encukou pushed a commit that referenced this issue Nov 25, 2024
* Make `create_shelllink_persist` top level function.

* Add `CopyComPointerTests`.

* Add more tests.

* Update tests.

* Add assertions for `Release`'s return value.
miss-islington pushed a commit to miss-islington/cpython that referenced this issue Nov 25, 2024
* Make `create_shelllink_persist` top level function.

* Add `CopyComPointerTests`.

* Add more tests.

* Update tests.

* Add assertions for `Release`'s return value.
(cherry picked from commit c7f1e3e)

Co-authored-by: Jun Komoda <45822440+junkmd@users.noreply.github.com>
miss-islington pushed a commit to miss-islington/cpython that referenced this issue Nov 25, 2024
* Make `create_shelllink_persist` top level function.

* Add `CopyComPointerTests`.

* Add more tests.

* Update tests.

* Add assertions for `Release`'s return value.
(cherry picked from commit c7f1e3e)

Co-authored-by: Jun Komoda <45822440+junkmd@users.noreply.github.com>
encukou pushed a commit that referenced this issue Nov 26, 2024
…127251)

gh-127183: Add `_ctypes.CopyComPointer` tests (GH-127184)

* Make `create_shelllink_persist` top level function.

* Add `CopyComPointerTests`.

* Add more tests.

* Update tests.

* Add assertions for `Release`'s return value.
(cherry picked from commit c7f1e3e)

Co-authored-by: Jun Komoda <45822440+junkmd@users.noreply.github.com>
encukou pushed a commit that referenced this issue Nov 26, 2024
…127252)

gh-127183: Add `_ctypes.CopyComPointer` tests (GH-127184)

* Make `create_shelllink_persist` top level function.

* Add `CopyComPointerTests`.

* Add more tests.

* Update tests.

* Add assertions for `Release`'s return value.
(cherry picked from commit c7f1e3e)

Co-authored-by: Jun Komoda <45822440+junkmd@users.noreply.github.com>
@encukou encukou closed this as completed Nov 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
tests Tests in the Lib/test dir topic-ctypes type-feature A feature request or enhancement
Projects
None yet
Development

No branches or pull requests

3 participants