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

[FunctionNaming] Don't allow the usage of ` in function names #4439

Merged
merged 1 commit into from Jan 3, 2022

Conversation

BraisGabin
Copy link
Member

From the Kotlin Coding conventions:

In tests (and only in tests), you can use method names with spaces enclosed in backticks.

https://kotlinlang.org/docs/coding-conventions.html#names-for-test-methods

And we are excluding this rule from test source sets so there is not point to alow it. It just allow false-negatives in production code.

@BraisGabin BraisGabin added this to the 1.20.0 milestone Jan 2, 2022
@BraisGabin BraisGabin force-pushed the dont-allow-backtick-in-function-names branch from a1181a2 to eac3708 Compare January 2, 2022 19:23
@BraisGabin BraisGabin force-pushed the dont-allow-backtick-in-function-names branch from eac3708 to 9eeff76 Compare January 2, 2022 20:00
@codecov
Copy link

codecov bot commented Jan 2, 2022

Codecov Report

Merging #4439 (9eeff76) into main (eb0f1cf) will not change coverage.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##               main    #4439   +/-   ##
=========================================
  Coverage     84.32%   84.32%           
  Complexity     3293     3293           
=========================================
  Files           472      472           
  Lines         10522    10522           
  Branches       1885     1885           
=========================================
  Hits           8873     8873           
  Misses          671      671           
  Partials        978      978           
Impacted Files Coverage Δ
...b/arturbosch/detekt/rules/naming/FunctionNaming.kt 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 eb0f1cf...9eeff76. Read the comment docs.

@chao2zhang chao2zhang merged commit ff7824d into main Jan 3, 2022
@chao2zhang chao2zhang deleted the dont-allow-backtick-in-function-names branch January 3, 2022 05:53
@cortinico cortinico added the rules label Jan 3, 2022
@cortinico cortinico changed the title Don't allow the usage of ` in function names [FunctionNaming] Don't allow the usage of ` in function names Jan 3, 2022
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

4 participants