Unit tests/fixes for PerformanceEntryObserver::get/clearEntries (#36384)

Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/36384

## Changelog:
[Internal] - Adds more test coverage to PerformanceEntryObserver functionality related to buffering of the marks/measures, as well as making fixes for certain corner cases handled incorrectly (which are now covered by tests).

Reviewed By: rubennorte

Differential Revision: D43835928

fbshipit-source-id: fc8adbd6c2a2b6b201f1f14bdf51245268c5eabd
This commit is contained in:
Ruslan Shestopalyuk
2023-03-06 15:23:02 -08:00
committed by Facebook GitHub Bot
parent 24dbb5df0a
commit ea354d4e22
3 changed files with 131 additions and 5 deletions
@@ -164,8 +164,9 @@ void PerformanceEntryReporter::clearEntries(
marksCount_ = 0;
marksRegistry_.clear();
}
} else if (
entryType == PerformanceEntryType::MEASURE ||
}
if (entryType == PerformanceEntryType::MEASURE ||
entryType == PerformanceEntryType::UNDEFINED) {
if (entryName != nullptr) {
clearCircularBuffer(