Skip to content

Commit f692f5f

Browse files
pidarpedandy31415
andcommitted
Pass largepayload flag into CommandSender in IM test app.
Use the session information from DeviceProxy to construct CommandSender for large payload if session supports it. Co-authored-by: Andrei Litvin <andy314@gmail.com>
1 parent 8ba371a commit f692f5f

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

src/app/tests/suites/commands/interaction_model/InteractionModel.h

+6-4
Original file line numberDiff line numberDiff line change
@@ -249,10 +249,12 @@ class InteractionModelCommands
249249
while (repeat--)
250250
{
251251

252-
chip::app::CommandPathParams commandPath = { endpointId, clusterId, commandId,
253-
(chip::app::CommandPathFlags::kEndpointIdValid) };
254-
auto commandSender = std::make_unique<chip::app::CommandSender>(
255-
mCallback, device->GetExchangeManager(), mTimedInteractionTimeoutMs.HasValue(), mSuppressResponse.ValueOr(false));
252+
chip::app::CommandPathParams commandPath = { endpointId, clusterId, commandId,
253+
(chip::app::CommandPathFlags::kEndpointIdValid) };
254+
std::unique_ptr<chip::app::CommandSender> commandSender = std::make_unique<chip::app::CommandSender>(
255+
mCallback, device->GetExchangeManager(), mTimedInteractionTimeoutMs.HasValue(), mSuppressResponse.ValueOr(false),
256+
device->GetSecureSession().Value()->AllowsLargePayload());
257+
256258
VerifyOrReturnError(commandSender != nullptr, CHIP_ERROR_NO_MEMORY);
257259

258260
chip::app::CommandSender::AddRequestDataParameters addRequestDataParams(mTimedInteractionTimeoutMs);

0 commit comments

Comments
 (0)