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

Allow additionalJavaSourceRootPaths to be defined on @KotlinCoreEnvironmentTest #4771

Merged
merged 10 commits into from Jun 1, 2022

Conversation

marschwar
Copy link
Contributor

This relates to #4575 and exposes the additionalJavaSourceRootPathsproperty from KotlinCoreEnvironmentWrapper.createEnvironment as additionalJavaSourcePaths in the KotlinCoreEnvironmentTest annotation.

There are only very few instances where this feature is needed, so the list of additionalJavaSourcePaths defaults to an empty list.

Changes in the tests are mostly indentation because I introduced two top level nested classes to split into WithDefaultSources and WithAdditionalJavaSources.

@vercel
Copy link

vercel bot commented Apr 25, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
detekt ✅ Ready (Inspect) Visit Preview Apr 25, 2022 at 7:55PM (UTC)

@codecov
Copy link

codecov bot commented Apr 25, 2022

Codecov Report

Merging #4771 (8620629) into main (a8cde4f) will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##               main    #4771   +/-   ##
=========================================
  Coverage     84.80%   84.80%           
  Complexity     3453     3453           
=========================================
  Files           492      492           
  Lines         11328    11328           
  Branches       2086     2086           
=========================================
  Hits           9607     9607           
  Misses          673      673           
  Partials       1048     1048           

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 a8cde4f...8620629. Read the comment docs.

Markus Schwarz added 2 commits April 26, 2022 07:42
…a-source

# Conflicts:
#	detekt-rules-style/src/test/kotlin/io/gitlab/arturbosch/detekt/rules/style/ExplicitCollectionElementAccessMethodSpec.kt
#	detekt-rules-style/src/test/kotlin/io/gitlab/arturbosch/detekt/rules/style/ObjectLiteralToLambdaSpec.kt
Copy link
Member

@BraisGabin BraisGabin left a comment

Choose a reason for hiding this comment

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

This PR shows the need of #4705 (and nearly all our tests). We have a lot of multiline strings and I don't even know how should we indent them "properly".

@marschwar
Copy link
Contributor Author

I don't think I understand that comment. I introduced and additional level of nesting and that changes the indentation. I do not see this as evidence that we need the multi-line string rule - even though it might still be a good rule to have.

@marschwar marschwar marked this pull request as draft April 26, 2022 07:32
@BraisGabin
Copy link
Member

I don't think I understand that comment. I introduced and additional level of nesting and that changes the indentation. I do not see this as evidence that we need the multi-line string rule - even though it might still be a good rule to have.

Captura de pantalla 2022-04-30 a las 13 02 48

You are adding indentation to your code, but if you see that code inside the multiline didn't change its indentation. The code inside the multiline string has less indentation that the opening multiline operator """.

@marschwar
Copy link
Contributor Author

Ok, I get it now. Is there a correct way to indent multi line strings?

@BraisGabin
Copy link
Member

I assume that there should be. But I don't know which it is. To me, the important part is to be consistent.

@schalkms
Copy link
Member

schalkms commented Jun 1, 2022

@marschwar @BraisGabin any plans to get this ahead?

@marschwar
Copy link
Contributor Author

From my point of view this is ready.

@BraisGabin BraisGabin added this to the 1.21.0 milestone Jun 1, 2022
@BraisGabin
Copy link
Member

More than 1 month with an approve and no open comments seems fair to merge to me so...

@BraisGabin BraisGabin merged commit 23a03e1 into detekt:main Jun 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants