google-cloud-cpp
google-cloud-cpp copied to clipboard
cleanup(pubsublite): fix integration test resource cleanup
In #9678, I forgot to set topic_name_ upon initialization, so we were not deleting the topic in the test's destructor. Oops, my bad.
https://github.com/googleapis/google-cloud-cpp/blob/ad5acebb8a413baeafbb2fb9857fc2086215795e/google/cloud/pubsublite/integration_tests/publisher_integration_test.cc#L85
I noticed that most leaked topics were getting deleted, though. Turns out we will make a request like projects/cloud-cpp-testing-resources/locations/..., but receive a response like: projects/123456789/locations/..... So the string comparison to check whether a topic was stale was always coming up true. Fix this by only comparing the topic id.
Google Cloud Build Logs
For commit: 42ee627224b0e2644c65356986d17e8b28372239
- Public Access Build Logs
- Cloud Build Console (requires auth)
- Kokoro Logs (requires auth)
:information_source: NOTE: Kokoro logs are linked from "Details" below.
Codecov Report
Merging #9685 (42ee627) into main (ad5aceb) will increase coverage by
0.00%. The diff coverage isn/a.
@@ Coverage Diff @@
## main #9685 +/- ##
=======================================
Coverage 94.29% 94.29%
=======================================
Files 1494 1494
Lines 139063 139063
=======================================
+ Hits 131124 131126 +2
+ Misses 7939 7937 -2
| Impacted Files | Coverage Δ | |
|---|---|---|
| ...le/cloud/internal/default_completion_queue_impl.cc | 96.59% <0.00%> (-0.57%) |
:arrow_down: |
| google/cloud/pubsub/samples/samples.cc | 90.77% <0.00%> (+0.07%) |
:arrow_up: |
| ...cloud/pubsub/internal/subscription_session_test.cc | 98.15% <0.00%> (+0.33%) |
:arrow_up: |
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.