Fix code presenter Browse Implementors - #1923
Conversation
AlexisCnockaert
commented
Jun 25, 2026
- So now it calls the new method browser, and we clean up the callsites
- So now it calls the new method browser, and we clean up the callsites
|
Hi, this fix is wrong. Tests are breaking because they were expecting to pass through system navigation and this is now hardcoding Smalltalk, tools, and other stuff again. I'll revert it. |
| ifTrue: [ self systemNavigation browse: variable value ] | ||
| ifFalse: [ self systemNavigation browseAllImplementorsOf: variableOrClassName ] | ||
| ifFalse: [ | ||
| (Smalltalk tools toolNamed: #messageList) browseImplementorsOfAll: { variableOrClassName } from: self interactionModel behavior ] |
There was a problem hiding this comment.
The right fix should be to pass though system navigation here, as it was before.
If we need to add an argument for the origin class, that should be extended there too.
And maybe we need to support the old method too for some time as a compatibility measure.
There was a problem hiding this comment.
This is the cause of the failing tests:
- SpCodePresenterTest testDoBrowseSenders
- SpCodePresenterTest testDoBrowseSendersOfClassNameShouldNotFindIfNotInEnvironment
- SpCodePresenterTest testDoBrowseSendersOfClassNameWhenInPlaygroundButNotAvailable
- SpCodePresenterTest testDoBrowseSendersOfClassPoolVariableShouldSelectClassPoolVariableUsersWhenInDebuggerButNotAvailable
- SpCodePresenterTest testDoBrowseSendersOfClassVariableShouldSelectClassVariableUsersWhenInDebuggerButNotAvailable
- SpCodePresenterTest testDoBrowseSendersOfClassVariableShouldSelectClassVariableUsersWhenInStaticContextButNotAvailable
|
Hi, I understand why, I did this because the new method browser works with tabs now. Therefore if someone want to browse implementors in a method browser it will not open as a tab but as a new window since it calls the system navigation. |
|
My point is not that the feature is bad! My point is that we should redo it, just being careful of respecting the architecture and keeping tests green!! :) |