From 4e611af2fbc5c493ecd46feb5024793a82b7807f Mon Sep 17 00:00:00 2001 From: jatinwadhwa921 Date: Sun, 28 Jun 2026 21:54:20 -0700 Subject: [PATCH] Addressing review comments --- .../providers/openvino/openvino_ep_workload_type_test.cc | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/onnxruntime/test/providers/openvino/openvino_ep_workload_type_test.cc b/onnxruntime/test/providers/openvino/openvino_ep_workload_type_test.cc index 5b9e4539f02a9..7d042b2c2e1ee 100644 --- a/onnxruntime/test/providers/openvino/openvino_ep_workload_type_test.cc +++ b/onnxruntime/test/providers/openvino/openvino_ep_workload_type_test.cc @@ -32,9 +32,14 @@ class OVEPWorkloadTypeTests : public ::testing::Test { } // Allow NPU resources to be fully released between tests. - // Without this delay the NPU driver may fail to re-initialise + // Without this delay the NPU driver may fail to re-initialise. + // Skip the delay when the test was skipped (e.g. no NPU available), since no + // NPU resources were acquired and the sleep would only add build latency. void TearDown() override { - std::this_thread::sleep_for(std::chrono::milliseconds(200)); + if (IsSkipped()) { + return; + } + std::this_thread::sleep_for(std::chrono::milliseconds(50)); } static Ort::Session CreateSqueezeNetSession(