Skip to content

Conversation

@chinglee-iot
Copy link
Owner

@chinglee-iot chinglee-iot commented Feb 6, 2023

Adding coverage test for xTaskResumeFromISR

Description

  • Add test_xTaskResumeFromISR_resume_higher_priority_suspended_task coverage test function
  • Add test_xTaskResumeFromISR_resume_lower_priority_suspended_task coverage test function

Test Steps

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.

* Adding coverage test for xTaskResumeFromISR
* This test can be run with FreeRTOS configured for any number of cores
* greater than 1 .
*
* Tasks are created prior to starting the scheduler.
Copy link
Collaborator

Choose a reason for hiding this comment

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

I think the description could probably be simpler (depending on the test). This portion should describe any setup or pre-conditioning required to take a particular code path. Perhaps we should also include a code snippet of the specific code path we are taking for coverage.

My concern is that when code changes it is difficult to determine which code coverage test needs to be updated to match. This can result in creating unnecessary coverage tests over time.

Copy link
Owner Author

@chinglee-iot chinglee-iot Feb 8, 2023

Choose a reason for hiding this comment

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

Code could also be changed in the future. In this case, code snippet will need extra effort to maintain.

I would like to use API and comment for tracking. At least when we change the code of an API, we can search for the test cases we may also need to update.
test_coverage_<API>_<test description>
<API> can be public API or private API.

@chinglee-iot chinglee-iot requested a review from joshzarr February 9, 2023 05:11
* Move the covg test to the folder have same FreeRTOSConfig.h
* Add configUSE_TICKLESS_IDLE config in single_priority_no_timeslice test group
* Move the utest.c file to single_priority_timeslice folder
Copy link
Collaborator

@joshzarr joshzarr left a comment

Choose a reason for hiding this comment

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

Looks good!

@chinglee-iot chinglee-iot deleted the smp-utest-xTaskResumeFromISR-covg branch April 20, 2023 08:32
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.

3 participants