Skip to content

Commit ccb6775

Browse files
committed
Change to test.
1 parent 33f5bd5 commit ccb6775

File tree

1 file changed

+14
-9
lines changed

1 file changed

+14
-9
lines changed

test/conformance/queue/urQueueCreate.cpp

Lines changed: 14 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -77,18 +77,23 @@ TEST_P(urQueueCreateTest, InvalidValueProperties) {
7777
}
7878

7979
TEST_P(urQueueCreateTest, InvalidQueueProperties) {
80+
ur_queue_properties_t props = {
81+
/*.stype =*/UR_STRUCTURE_TYPE_QUEUE_PROPERTIES,
82+
/*.pNext =*/nullptr,
83+
/*.flags =*/UR_QUEUE_FLAG_PRIORITY_HIGH | UR_QUEUE_FLAG_PRIORITY_LOW,
84+
};
85+
// It should be an error to specify both low/high priorities
86+
{
8087
ur_queue_handle_t queue = nullptr;
81-
ur_queue_properties_t props = {
82-
/*.stype =*/UR_STRUCTURE_TYPE_QUEUE_PROPERTIES,
83-
/*.pNext =*/nullptr,
84-
/*.flags =*/UR_QUEUE_FLAG_PRIORITY_HIGH | UR_QUEUE_FLAG_PRIORITY_LOW |
85-
UR_QUEUE_FLAG_SUBMISSION_BATCHED |
86-
UR_QUEUE_FLAG_SUBMISSION_IMMEDIATE,
87-
};
88-
// It should be an error to specify both low/high priorities
8988
ASSERT_EQ_RESULT(UR_RESULT_ERROR_INVALID_QUEUE_PROPERTIES,
9089
urQueueCreate(context, device, &props, &queue));
91-
// It should be an error to specify both batched and immediate submission
90+
}
91+
// It should be an error to specify both batched and immediate submission
92+
{
93+
ur_queue_handle_t queue = nullptr;
94+
props.flags =
95+
UR_QUEUE_FLAG_SUBMISSION_BATCHED | UR_QUEUE_FLAG_SUBMISSION_IMMEDIATE;
9296
ASSERT_EQ_RESULT(UR_RESULT_ERROR_INVALID_QUEUE_PROPERTIES,
9397
urQueueCreate(context, device, &props, &queue));
98+
}
9499
}

0 commit comments

Comments
 (0)