-
Notifications
You must be signed in to change notification settings - Fork 241
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 java invalid base dir #900
Conversation
Opps, need to rebase on to clean origin/master |
cea4b6d
to
32890c4
Compare
Codecov Report
@@ Coverage Diff @@
## master #900 +/- ##
=============================================
- Coverage 60.02% 44.44% -15.58%
+ Complexity 605 468 -137
=============================================
Files 159 159
Lines 5223 5231 +8
Branches 653 654 +1
=============================================
- Hits 3135 2325 -810
- Misses 1810 2685 +875
+ Partials 278 221 -57
Continue to review full report at Codecov.
|
.forceWhenUptodate() | ||
.use(ProgressExecutionMode.MODAL_SYNC) | ||
|
||
ExternalSystemUtil.refreshProjects(importSpecBuilder) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
does this happen synchronously?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, that is controlled by the ProgressExecutionMode enum 2 lines up
assertThatThrownBy { | ||
buildLambda(projectRule.module, handlerPsi, Runtime.JAVA8, "com.example.SomeClass") | ||
}.isInstanceOf(IllegalStateException::class.java) | ||
.hasMessageEndingWith("is not managed by Maven or Gradle") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm, as the exception message is managed by the localization properties, I'm wondering if it is appropriate to test the exception message
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ya it is fragile, but it does enforce the correct exception is thrown and not a random different IllegalState
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I understand you want to enforce the correct exception. It's better to fix the fragile test, but I'm fine with it too considering we are not expanding the localization in a short term.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can just use the message() call here as well. I'll make the change tomorrow
32890c4
to
6ec659c
Compare
…for Java * When using Java handler based build, query Maven/Gradle for the project root.
6ec659c
to
75bdbe0
Compare
Types of changes
Description
Query project root from Maven/Gradle to determine the base directory for Java
When using Java handler based build, query Maven/Gradle for the project root.
Motivation and Context
Related Issue(s)
#868, #857
Testing
We now actually import the projects and then try to build them
Screenshots (if appropriate)
License
I confirm that my contribution is made under the terms of the Apache 2.0 license.