Skip to content
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

Add While expression mutator #1405

Merged
merged 1 commit into from Nov 2, 2020
Merged

Add While expression mutator #1405

merged 1 commit into from Nov 2, 2020

Conversation

sidz
Copy link
Member

@sidz sidz commented Nov 2, 2020

This PR:

Mutates:

$condition = true;
- while ($condition) {
+ while (false) {

@sidz sidz added the Mutator label Nov 2, 2020
@sidz sidz self-assigned this Nov 2, 2020
sidz added a commit to infection/site that referenced this pull request Nov 2, 2020
Copy link
Member

@maks-rafalko maks-rafalko left a comment

Choose a reason for hiding this comment

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

Cool.

What about do while()? should we add similar mutator?

@sidz
Copy link
Member Author

sidz commented Nov 2, 2020

@maks-rafalko yes we should and I also have a plan to add it but it is not a ZeroIteration mutator. I'm thinking about deprecate @zero_iteration profile in favor of @loop (we also have Loop section in documentation).

But not sure how to achieve this with json schema validator so far. (found that latest shcema (https://json-schema.org/draft/2019-09/release-notes.html#meta-data-vocabulary) has "deprecated" property)

Or we may do it a bit aggressive and just rename zero_iteration profile to loop and release in the next "major".

what do you think @maks-rafalko, @sanmai ?

@sanmai
Copy link
Member

sanmai commented Nov 2, 2020

I'm for the rename. Next major assumes BC breaks, and that's what it is.

@sidz sidz merged commit 14f0ee0 into master Nov 2, 2020
@sidz
Copy link
Member Author

sidz commented Nov 2, 2020

thanks @maks-rafalko , @sanmai

@sidz sidz deleted the while-expression-mutator branch November 2, 2020 14:28
sidz added a commit to infection/site that referenced this pull request Nov 2, 2020
@maks-rafalko maks-rafalko added this to the 0.21.0 milestone Nov 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants