Skip to content

Commit

Permalink
Fix coverage false positive in test by ignoring it.
Browse files Browse the repository at this point in the history
  • Loading branch information
pradn committed Feb 25, 2022
1 parent 8bcd00b commit 4b5f846
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions tests/unit/pubsub_v1/subscriber/test_messages_on_hold.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,19 +19,14 @@
from google.pubsub_v1 import types as gapic_types


# Using this function instead of a lambda to satisfy the coverage tool
def return_false():
return False


def make_message(ack_id, ordering_key):
proto_msg = gapic_types.PubsubMessage(data=b"Q", ordering_key=ordering_key)
return message.Message(
proto_msg._pb,
ack_id,
0,
queue.Queue(),
exactly_once_delivery_enabled_func=return_false,
exactly_once_delivery_enabled_func=lambda: False, # pragma: NO COVER
)


Expand Down

0 comments on commit 4b5f846

Please sign in to comment.