Closed akurtakov closed 10 months ago
One step further in making https://github.com/eclipse-jdt/eclipse.jdt.core/issues/1106 usabel in the IDE.
@akurtakov : can you please add a test that launches "simple modern" main? It should fail without your patch.
So there are no specific test plugins for debug.ui or launching plugins. Do I assume correct that https://github.com/eclipse-jdt/eclipse.jdt.debug/blob/master/org.eclipse.jdt.debug.tests is the place to put such tests or should I start new dedicated bundles?
Some hints where exactly to put such tests in the current structure would be much appreciated.
So there are no specific test plugins for debug.ui or launching plugins. Do I assume correct that https://github.com/eclipse-jdt/eclipse.jdt.debug/blob/master/org.eclipse.jdt.debug.tests is the place to put such tests
Right. Briefly looking at it, something similar to org.eclipse.jdt.debug.tests.breakpoints.MiscBreakpointsTests
or org.eclipse.jdt.debug.tests.launching.LongClassPathTests
- they use org.eclipse.jdt.debug.tests.AbstractDebugTest.launchAndXXX()
API. But maybe you can find a better test for inspiration.
Some hints where exactly to put such tests in the current structure would be much appreciated.
Somewhere at org.eclipse.jdt.debug.tests.launching
This proves that instance main methods are called. I don't think it's needed to repeat the extensive tests as done in jdt.core as the debug code actually calls isMainMethodCandidate which is extensively tested in core.
This proves that instance main methods are called. I don't think it's needed to repeat the extensive tests as done in jdt.core as the debug code actually calls isMainMethodCandidate which is extensively tested in core.
Sure. Unfortunately both new tests fail: https://ci.eclipse.org/jdt/job/eclipse.jdt.debug-github/job/PR-326/6/#showFailuresLink
Sure. Unfortunately both new tests fail: https://ci.eclipse.org/jdt/job/eclipse.jdt.debug-github/job/PR-326/6/#showFailuresLink
I'm trying to figure out why it's not using Java 21 .
So the failure is due to:
Loading trusted files from base branch master at dc3a1d9b6ba09c2931ad39487bfa4506fe360152 rather than f44e7e2fde7b33b39eb257bff065ba89859f2c01
Obtained Jenkinsfile from dc3a1d9b6ba09c2931ad39487bfa4506fe360152
‘Jenkinsfile’ has been modified in an untrusted revision
As I not a committer my change to Jenkinsfile is simply ignored. @jjohnstn @rgrunber Would you please push the Jenkinsfile change in its own PR so I care rebase this one on top of it?
@jjohnstn Thanks for the fast jenkinsfile change. This PR is ready for review now.
@iloveeclipse As you already looked at this one do you want to finish the review?
What it does
Using isMainMethodCandidate ensures there is at least one main method so JVM will be able to launch.
How to test
Create a class with public/protected/default non-static main method with or without String[] args and verify that Run As/Debug As works.
Author checklist