Skip to content

feature: Add test for clamping NotifyOnNReports#361

Open
weswaugh wants to merge 1 commit into
oneapi-src:masterfrom
weswaugh:VCV-15442
Open

feature: Add test for clamping NotifyOnNReports#361
weswaugh wants to merge 1 commit into
oneapi-src:masterfrom
weswaugh:VCV-15442

Conversation

@weswaugh

Copy link
Copy Markdown
Contributor

Resolves: VCV-15442

Resolves: VCV-15442

Signed-off-by: Waugh, Wesley <wesley.waugh@intel.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a conformance test to validate that notifyEveryNReports is clamped (rather than failing or overflowing) when an extremely large value is requested for an IP, time-based metric streamer.

Changes:

  • Added a new zetMetricStreamerTest case that opens a metric streamer with notifyEveryNReports = UINT32_MAX.
  • Added assertions that the returned notifyEveryNReports value is clamped to a smaller, non-zero value.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +3056 to +3057
auto groupInfo = metricGroupInfo[0];
lzt::activate_metric_groups(device, 1, &groupInfo.metricGroupHandle);
Comment on lines +3061 to +3064
auto streamer = lzt::metric_streamer_open_for_device(
device, groupInfo.metricGroupHandle, nullptr, requestedNotify, period);
ASSERT_NE(nullptr, streamer);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants