Skip to content

Fix empty true branch & correct generic execution selection logic in parametrized test generation #683 #682

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 9, 2022

Conversation

sofurihafe
Copy link
Member

@sofurihafe sofurihafe commented Aug 8, 2022

Description

This PR fixes a bug with empty true branch body in parametrized test generation.
Also, the logic of selecting generic execution was corrected a little. Now, if there are no successful executions with non-null result, instead of selecting the first random one, we select the first successful execution with null result.

Fixes # (683)

Type of Change

  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

Automated Testing

Run utbot samples with enabled parametrized test generation.

Manual Scenario

Run testMockInterfaceWithoutImplementors test. Verify that if-statement true branch contains an assertion.

@sofurihafe sofurihafe force-pushed the andrey-t/generic-execution branch 2 times, most recently from 8697bd1 to 8ff2ce6 Compare August 8, 2022 11:49
@sofurihafe sofurihafe changed the title wip Fix empty true branch & correct generic execution selection logic in parametrized test generation Aug 8, 2022
@sofurihafe sofurihafe changed the title Fix empty true branch & correct generic execution selection logic in parametrized test generation Fix empty true branch & correct generic execution selection logic in parametrized test generation #683 Aug 8, 2022
@sofurihafe sofurihafe marked this pull request as ready for review August 8, 2022 12:14
@sofurihafe sofurihafe force-pushed the andrey-t/generic-execution branch from 123f8b9 to 7388c38 Compare August 8, 2022 13:20
@sofurihafe sofurihafe linked an issue Aug 8, 2022 that may be closed by this pull request
@sofurihafe sofurihafe force-pushed the andrey-t/generic-execution branch from 7388c38 to 42290f8 Compare August 8, 2022 15:05
@sofurihafe sofurihafe force-pushed the andrey-t/generic-execution branch from 42290f8 to 87393f9 Compare August 9, 2022 12:33
@sofurihafe sofurihafe force-pushed the andrey-t/generic-execution branch from 87393f9 to 62a51bd Compare August 9, 2022 13:39
@EgorkaKulikov EgorkaKulikov merged commit 71723a9 into main Aug 9, 2022
@EgorkaKulikov EgorkaKulikov deleted the andrey-t/generic-execution branch August 9, 2022 15:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Empty true branch in generated parametrized test
2 participants