From 61c22a4f4fbed418213fd450f0a23a1e6addd027 Mon Sep 17 00:00:00 2001 From: Johan Brichau Date: Fri, 25 Oct 2024 11:44:53 +0200 Subject: [PATCH 1/8] Author was removed in Pharo 13: disregard setting the author when using version 13... --- .../WADevelopment.class/class/ensureAuthorInitialsWith..st | 3 ++- .../instance/seasideIsAuthorNameSet.st | 4 +++- .../instance/seasideSetAuthorName..st | 4 +++- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/repository/Seaside-Pharo-Development.package/WADevelopment.class/class/ensureAuthorInitialsWith..st b/repository/Seaside-Pharo-Development.package/WADevelopment.class/class/ensureAuthorInitialsWith..st index 9b0dc1d36..b4ac5843a 100644 --- a/repository/Seaside-Pharo-Development.package/WADevelopment.class/class/ensureAuthorInitialsWith..st +++ b/repository/Seaside-Pharo-Development.package/WADevelopment.class/class/ensureAuthorInitialsWith..st @@ -7,7 +7,8 @@ ensureAuthorInitialsWith: aOneArgumentBlock ifTrue: [ "Special Pharo code path to avoid deprecation" | author | - author := Smalltalk at: #Author. + SystemVersion current major >= 13 ifTrue:[ ^ self. "do nothing because Author does not exist anymore" ]. + author := Smalltalk at: #Author ifAbsent: [ nil ]. author isNil ifTrue: [ ^ self error: 'unsupported Pharo version' ]. author fullNamePerSe isEmptyOrNil diff --git a/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideIsAuthorNameSet.st b/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideIsAuthorNameSet.st index 25e394870..b305eb31d 100644 --- a/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideIsAuthorNameSet.st +++ b/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideIsAuthorNameSet.st @@ -1,3 +1,5 @@ *seaside-pharo-welcome seasideIsAuthorNameSet - ^ Author fullNamePerSe isEmptyOrNil not \ No newline at end of file + + SystemVersion current major >= 13 ifTrue:[ ^ true. "Author does not exist anymore" ]. + ^ (Smalltalk at: #Author) fullNamePerSe isEmptyOrNil not \ No newline at end of file diff --git a/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideSetAuthorName..st b/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideSetAuthorName..st index 5f7a84cad..98a40c20c 100644 --- a/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideSetAuthorName..st +++ b/repository/Seaside-Pharo-Welcome.package/GRPharoPlatform.extension/instance/seasideSetAuthorName..st @@ -1,3 +1,5 @@ *seaside-pharo-welcome seasideSetAuthorName: anAuthorName - Author fullName: anAuthorName \ No newline at end of file + + SystemVersion current major >= 13 ifTrue:[ ^ self error: 'Author does not exist anymore.' ]. + (Smalltalk at: #Author) fullName: anAuthorName \ No newline at end of file From d2b3dd764e3d5cf03ab7a80b6ad532b046d27c94 Mon Sep 17 00:00:00 2001 From: Johan Brichau Date: Fri, 25 Oct 2024 14:11:36 +0200 Subject: [PATCH 2/8] Move Seaside control panel to a separate top-level Seaside menu (ready for more to come) --- .../{menuCommandOn..st => controlPanelMenuCommandOn..st} | 8 ++++---- .../class/seasideMenuCommandOn..st | 7 +++++++ 2 files changed, 11 insertions(+), 4 deletions(-) rename repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/{menuCommandOn..st => controlPanelMenuCommandOn..st} (68%) create mode 100644 repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/seasideMenuCommandOn..st diff --git a/repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/menuCommandOn..st b/repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/controlPanelMenuCommandOn..st similarity index 68% rename from repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/menuCommandOn..st rename to repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/controlPanelMenuCommandOn..st index 7ca6d9052..ceaff0471 100644 --- a/repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/menuCommandOn..st +++ b/repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/controlPanelMenuCommandOn..st @@ -1,10 +1,10 @@ world menu -menuCommandOn: aBuilder +controlPanelMenuCommandOn: aBuilder - self registerIcons. + (aBuilder item: #ServerAdapterBrowser) - order: 0.21; - parent: #Tools; + order: 1; + parent: #Seaside; label: 'Seaside Control Panel'; icon: (self iconNamed: #adaptorRunningIcon); action: [ self open ] \ No newline at end of file diff --git a/repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/seasideMenuCommandOn..st b/repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/seasideMenuCommandOn..st new file mode 100644 index 000000000..c100e420c --- /dev/null +++ b/repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/seasideMenuCommandOn..st @@ -0,0 +1,7 @@ +world menu +seasideMenuCommandOn: builder + + + (builder item: #Seaside) + target: self; + order: 1.4 \ No newline at end of file From 7738e58f01bbf8d3f43261d802568469eb65a55d Mon Sep 17 00:00:00 2001 From: Johan Brichau Date: Fri, 25 Oct 2024 14:36:54 +0200 Subject: [PATCH 3/8] run ci on ubuntu latest --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5e14adcf8..3bf0eb100 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -4,7 +4,7 @@ on: [push, pull_request] jobs: test: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest strategy: fail-fast: false matrix: From a87c9c83822f52a2985c89d3d5ad94e70da42cc2 Mon Sep 17 00:00:00 2001 From: Johan Brichau Date: Fri, 25 Oct 2024 14:48:49 +0200 Subject: [PATCH 4/8] added code to see why an assertion is broken in the CI --- .../instance/testTableReportFunctionalTest.st | 3 +++ 1 file changed, 3 insertions(+) diff --git a/repository/Seaside-Tests-Parasol.package/WAWebDriverFunctionalTestCase.class/instance/testTableReportFunctionalTest.st b/repository/Seaside-Tests-Parasol.package/WAWebDriverFunctionalTestCase.class/instance/testTableReportFunctionalTest.st index 38dd6249c..f8efbe4ad 100644 --- a/repository/Seaside-Tests-Parasol.package/WAWebDriverFunctionalTestCase.class/instance/testTableReportFunctionalTest.st +++ b/repository/Seaside-Tests-Parasol.package/WAWebDriverFunctionalTestCase.class/instance/testTableReportFunctionalTest.st @@ -5,6 +5,9 @@ testTableReportFunctionalTest firstColumn := driver findElementsByCSSSelector: 'table>tbody>tr>td:first-child'. classNames := (firstColumn collect: [ :e | e getText ]). + ((WAComponent allSubclasses collect: [ :c | c name greaseString ]) + reject: [ :className | classNames includes: className ]) + do: [ :className | Transcript show: className ]. self assert: ((WAComponent allSubclasses collect: [ :c | c name greaseString ]) allSatisfy: [ :className | classNames includes: className ]). ((driver findElementByCSSSelector: 'table>thead') findElementByPartialLinkText: 'Name') click. From f3d68c08814d1776cf0a1217b24f44a1e89d5fcd Mon Sep 17 00:00:00 2001 From: Johan Brichau Date: Fri, 25 Oct 2024 15:00:11 +0200 Subject: [PATCH 5/8] add a delay to debug a test --- .../class/runSeleniumServerInTerminal.st | 10 ++++++++++ .../class/runSeleniumServerInTerminalMenuCommandOn..st | 9 +++++++++ .../class/seasideIcebergRepository.st | 6 ++++++ .../instance/testTableReportFunctionalTest.st | 2 +- 4 files changed, 26 insertions(+), 1 deletion(-) create mode 100644 repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/runSeleniumServerInTerminal.st create mode 100644 repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/runSeleniumServerInTerminalMenuCommandOn..st create mode 100644 repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/seasideIcebergRepository.st diff --git a/repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/runSeleniumServerInTerminal.st b/repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/runSeleniumServerInTerminal.st new file mode 100644 index 000000000..02cd9146c --- /dev/null +++ b/repository/Seaside-Pharo100-Tools-Spec2.package/WAPharoControlPanel.class/class/runSeleniumServerInTerminal.st @@ -0,0 +1,10 @@ +commands +runSeleniumServerInTerminal +