Skip to content

Conversation

@hallvictoria
Copy link
Contributor

@hallvictoria hallvictoria commented May 28, 2025

Currently, Blob (InputStream) and Timer (TimerRequest) types cannot be unit tested.

Doing something like req = func.TimerRequest() results in an error saying TypeError: Can't instantiate abstract class TimerRequest with abstract methods past_due. This is because both Blob and Timer are missing the abstract layer that the other types have. This change adds the layer, allowing for unit testing, but not changing any other details.

This change is already covered through our unit tests & does not impact current functionality.

Fixes Azure/azure-functions-python-worker#737

@hallvictoria hallvictoria marked this pull request as ready for review May 28, 2025 18:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] It is not possible to unit test a Python timer function

3 participants