Skip to content

Commit

Permalink
tests
Browse files Browse the repository at this point in the history
  • Loading branch information
lzchen committed Nov 22, 2024
1 parent 901c95e commit 46b519e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion contrib/opencensus-ext-azure/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
## Unreleased

- Remove status code `206` from retry code + only count batch level for statsbeat
([#1239](https://github.com/census-instrumentation/opencensus-python/pull/1239))
([#1247](https://github.com/census-instrumentation/opencensus-python/pull/1247))

## 1.1.13

Expand Down
5 changes: 3 additions & 2 deletions contrib/opencensus-ext-azure/tests/test_transport_mixin.py
Original file line number Diff line number Diff line change
Expand Up @@ -454,9 +454,10 @@ def test_statsbeat_206_partial_retry(self):
],
}))
result = mixin._transmit([1, 2, 3])
self.assertEqual(len(_requests_map), 3)
# We do not record any network statsbeat for 206 status code
self.assertEqual(len(_requests_map), 2)
self.assertIsNotNone(_requests_map['duration'])
self.assertEqual(_requests_map['retry'][500], 1)
self.assertIsNone(_requests_map.get('retry'))
self.assertEqual(_requests_map['count'], 1)
self.assertEqual(result, TransportStatusCode.DROP)
storage_mock.put.assert_called_once()
Expand Down

0 comments on commit 46b519e

Please sign in to comment.