Skip to content

Commit

Permalink
Cleaning GistPresenter and some other test
Browse files Browse the repository at this point in the history
  • Loading branch information
Ducasse committed Jan 30, 2025
1 parent d9a4a83 commit 5e174d5
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 21 deletions.
22 changes: 7 additions & 15 deletions Iceberg-Playground-Plugin-Gist/IcePublishGistPresenter.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -21,17 +21,11 @@ Class {
}

{ #category : 'accessing' }
IcePublishGistPresenter class >> initialExtent [
IcePublishGistPresenter class >> defaultPreferredExtent [

^ 600@400
]

{ #category : 'accessing' }
IcePublishGistPresenter class >> windowTitle [

^ 'Publish Gist'
]

{ #category : 'accessing' }
IcePublishGistPresenter >> content: aString [

Expand Down Expand Up @@ -88,14 +82,6 @@ IcePublishGistPresenter >> initializePresenters [
beForScripting
]

{ #category : 'initialization' }
IcePublishGistPresenter >> initializeWindow: aWindowPresenter [

aWindowPresenter
title: self class windowTitle;
initialExtent: self class initialExtent.
]

{ #category : 'actions' }
IcePublishGistPresenter >> publishThen: aBlock [
| description public jsonResult |
Expand Down Expand Up @@ -143,3 +129,9 @@ IcePublishGistPresenter >> whenPublishedDo: aBlock [

publishedAction := aBlock
]

{ #category : 'events' }
IcePublishGistPresenter >> windowTitle [

^ 'Publish Gist'
]
11 changes: 5 additions & 6 deletions Iceberg-UI-Tests/IceTipPresenterMetaTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -96,19 +96,18 @@ IceTipPresenterMetaTest >> testDefaultSpecDoesntUsePragma [
{ #category : 'tests' }
IceTipPresenterMetaTest >> testDoNotImplementDiscouragedSelectors [

"Either instance or class-side, the old #title is named #titleForWindow in inst-side."
self assertEmpty: (self presenterClassesDefining: #title isMeta: true).
self assertEmpty: (self presenterClassesDefining: #title isMeta: false).
"Either instance the old #title is named #windowTitle in inst-side."
self assertEmpty: (self presenterClassesDefining: #windowTitle isMeta: true).

"The #icon is called #iconForWindow in IceTip UI."
self assertEmpty: (self presenterClassesDefining: #icon isMeta: true).
"The #icon is called #windowIcon in IceTip UI."
self assertEmpty: (self presenterClassesDefining: #windowIcon isMeta: true).

"These methods are not yet deprecated via pragma, but discouraged in Spec2."
self assertEmpty: (self presenterClassesDefining: #initialExtent isMeta: false).
self assertEmpty: (self presenterClassesDefining: #initializeWidgets isMeta: false).
self assertEmpty: (self presenterClassesDefining: #initializePresenter isMeta: false).

self assertEmpty: (self presenterClassesDefining: #windowIcon isMeta: false).



]
Expand Down

0 comments on commit 5e174d5

Please sign in to comment.