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

Fix NotEqual position issue #325

Merged
merged 1 commit into from
Jun 29, 2020
Merged

Conversation

jimmylai
Copy link
Contributor

@jimmylai jimmylai commented Jun 29, 2020

Summary

PositionProvider provides inconsistent NotEqual (whitespaces are included) compare to Equal (whitespace is not included). Issue was reported in #315.
Not sure why NotEqual was implemented differently.
Use _BaseOneTokenOp to keep the codegen consistent and add test cases.

Test Plan

Add new test cases.

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Jun 29, 2020
@codecov-commenter
Copy link

codecov-commenter commented Jun 29, 2020

Codecov Report

Merging #325 into master will increase coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #325   +/-   ##
=======================================
  Coverage   93.98%   93.99%           
=======================================
  Files         225      225           
  Lines       21778    21787    +9     
=======================================
+ Hits        20469    20478    +9     
  Misses       1309     1309           
Impacted Files Coverage Δ
libcst/_nodes/op.py 95.66% <100.00%> (-0.03%) ⬇️
libcst/metadata/tests/test_position_provider.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2d56ba7...bcdbda8. Read the comment docs.

@jimmylai jimmylai requested review from carljm, josieesh and zsol June 29, 2020 04:41
Copy link
Member

@zsol zsol left a comment

Choose a reason for hiding this comment

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

lgtm

@jimmylai jimmylai merged commit 3a7ffaf into Instagram:master Jun 29, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants