Browse Source

bug(replays): Explicitly set storage sample rate to 0 (#52392)

If the filestore tests run after the direct storage tests then global
option will not be correct for the test run causing it to use the direct
storage api rather than the filestore API. By explicitly setting it to 0
we ensure the test always runs with the correct state.
Colton Allen 1 year ago
parent
commit
6bab6a04cc
1 changed files with 1 additions and 0 deletions
  1. 1 0
      tests/sentry/replays/consumers/test_recording.py

+ 1 - 0
tests/sentry/replays/consumers/test_recording.py

@@ -129,6 +129,7 @@ class FilestoreRecordingTestCase(RecordingTestCaseMixin, TransactionTestCase):
     def setUp(self):
         self.replay_id = uuid.uuid4().hex
         self.replay_recording_id = uuid.uuid4().hex
+        options.set("replay.storage.direct-storage-sample-rate", 0)
 
     def assert_replay_recording_segment(self, segment_id: int, compressed: bool):
         # Assert a recording segment model was created for filestore driver types.