Skip to content

Conversation

@aggarg
Copy link
Member

@aggarg aggarg commented Nov 2, 2022

Description

This test simulates the scenario when a task with priority higher than the currently executing task is unblocked as a result of the xTaskIncrementTick call.

This is needed to fix the coverage drop in PR FreeRTOS/FreeRTOS-Kernel#568.

Test Steps

cd FreeRTOS/Test/CMock/
make

Results:

Overall coverage rate:
  lines......: 96.4% (2288 of 2373 lines)
  functions..: 98.4% (187 of 190 functions)
  branches...: 94.1% (1189 of 1263 branches)

Related Issue

FreeRTOS/FreeRTOS-Kernel#568

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

This test simulates the scenario when a task with priority higher than
the currently executing task is unblocked as a result of the
xTaskIncrementTick call.

This is needed to fix the coverage drop in PR FreeRTOS/FreeRTOS-Kernel#568.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
@aggarg aggarg requested a review from a team as a code owner November 2, 2022 07:46
amazonKamath
amazonKamath previously approved these changes Nov 3, 2022
Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
@aggarg aggarg dismissed stale reviews from amazonKamath and AniruddhaKanhere via 25ff773 November 3, 2022 07:09
shubnil
shubnil previously approved these changes Nov 3, 2022
Copy link
Member

@moninom1 moninom1 left a comment

Choose a reason for hiding this comment

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

We can add comment for test_xTaskIncrementTick_success_unblock_tasks as well for covering all 3 cases.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
@AniruddhaKanhere AniruddhaKanhere merged commit aa316fc into FreeRTOS:main Nov 3, 2022
aggarg added a commit to aggarg/FreeRTOS that referenced this pull request Dec 9, 2023
FreeRTOS/FreeRTOS-Kernel#867

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
every-breaking-wave pushed a commit to every-breaking-wave/FreeRTOS that referenced this pull request Nov 15, 2024
This commit adds a portTASK_SWITCH_HOOK() macro which allows ports to inject
behavior immediately after a context switch. For example, this macro could be
used by ports that need to set an end of stack watchpoint after a context
swtich.

Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
Co-authored-by: Soren Ptak <ptaksoren@gmail.com>
Co-authored-by: chinglee-iot <61685396+chinglee-iot@users.noreply.github.com>
Co-authored-by: Tony Josi <tonyjosi@amazon.com>
Co-authored-by: Gaurav-Aggarwal-AWS <33462878+aggarg@users.noreply.github.com>
Zangetsu112 pushed a commit to Zangetsu112/FreeRTOS-evpp that referenced this pull request Aug 18, 2025
* Add a unit test for tasks.c

This test simulates the scenario when a task with priority higher than
the currently executing task is unblocked as a result of the
xTaskIncrementTick call.

This is needed to fix the coverage drop in PR FreeRTOS/FreeRTOS-Kernel#568.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>

* Add description for the test

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>

* Add doc for another test

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
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.

5 participants