Fix/update and add unit tests#346
Merged
AniruddhaKanhere merged 1 commit intoFreeRTOS:MQTTv5-reviewed-changesfrom Jan 17, 2026
Merged
Fix/update and add unit tests#346AniruddhaKanhere merged 1 commit intoFreeRTOS:MQTTv5-reviewed-changesfrom
AniruddhaKanhere merged 1 commit intoFreeRTOS:MQTTv5-reviewed-changesfrom
Conversation
e9aaa73 to
37e3b02
Compare
178edf9 to
f3ddfd4
Compare
Member
|
Coverage metrics per our chat: |
Comment on lines
+376
to
+377
| status = MQTTPropAdd_MaxPacketSize( &PropertyBuilder, 0, &OptionalMqttPacketType ); | ||
| TEST_ASSERT_EQUAL( MQTTBadParameter, status ); |
Member
There was a problem hiding this comment.
Nit: To keep consistent ordering move this to be the first test
Comment on lines
+1162
to
+1167
| PropertyBuilder.pBuffer = buffer; | ||
| PropertyBuilder.currentIndex = 0; | ||
| PropertyBuilder.bufferLength = 100; | ||
| PropertyBuilder.fieldSet = 0; | ||
| status = MQTTPropAdd_AuthData( &PropertyBuilder, "Hello", 5, &OptionalMqttPacketType ); | ||
| TEST_ASSERT_EQUAL( MQTTBadParameter, status ); |
Member
There was a problem hiding this comment.
Nit: for consistent ordering move this before the previous test
Comment on lines
+1480
to
+1485
| status = MQTTPropAdd_ResponseTopic( NULL, "hello", 5, &OptionalMqttPacketType ); | ||
| TEST_ASSERT_EQUAL( MQTTBadParameter, status ); | ||
|
|
||
| PropertyBuilder.pBuffer = NULL; | ||
| status = MQTTPropAdd_ResponseTopic( &PropertyBuilder, "hello", 5, &OptionalMqttPacketType ); | ||
| TEST_ASSERT_EQUAL( MQTTBadParameter, status ); |
Member
There was a problem hiding this comment.
This is checked in addPropUtf8. Move this below the next two tests which are defined directly in MQTTPropAdd_ResponseTopic.
41e437a to
ced71e4
Compare
Member
Author
|
Updated coverage rate: |
ced71e4 to
5123cf3
Compare
kstribrnAmzn
approved these changes
Jan 17, 2026
6da5853
into
FreeRTOS:MQTTv5-reviewed-changes
8 of 11 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Test Steps
Checklist:
Related Issue
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.