Skip to content

Commit caedcc7

Browse files
authored
Merge pull request #3 from JanBliznicenko/master
Fixed multiple infinite loop cases, converted files to Tonel v3.0
2 parents 7d7649d + 5973fd2 commit caedcc7

28 files changed

Lines changed: 343 additions & 209 deletions

.github/workflows/runTests.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ on:
77
branches: [ master ]
88
pull_request:
99
branches: [ master ]
10+
workflow_dispatch:
1011

1112

1213
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
@@ -16,7 +17,7 @@ jobs:
1617
strategy:
1718
fail-fast: false
1819
matrix:
19-
smalltalk: [ pharo9, pharo10, pharo11, pharo12 ]
20+
smalltalk: [ pharo9, pharo10, pharo11, pharo12, pharo13, pharo14 ]
2021
group: [ default ]
2122
tests: [ Roassal-Layouts ]
2223
os: [ ubuntu-latest ]
@@ -27,20 +28,20 @@ jobs:
2728
steps:
2829

2930
- name: Cancel Previous Runs
30-
uses: styfle/cancel-workflow-action@0.12.0
31+
uses: styfle/cancel-workflow-action@0.12.1
3132
with:
3233
access_token: ${{ github.token }}
3334

3435
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
3536
# depth 0 will download all the repository history
36-
- uses: actions/checkout@v3
37+
- uses: actions/checkout@v4.2.2
3738
with:
3839
fetch-depth: 0
3940

4041
# This will delete roassal and numeric scales and it executes the tests again
4142
- name: Run pharo Tests
4243
id: tests
43-
uses: akevalion/PharoTestsAction@v1
44+
uses: tinchodias/PharoTestsAction@v3
4445
with:
4546
removes-repo: 'Roassal, RoassalLayouts, Numeric'
4647
baseline: 'RoassalLayouts'

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@
44
[![CI](https://github.com/pharo-graphics/RoassalLayouts/actions/workflows/runTests.yml/badge.svg)](https://github.com/pharo-graphics/RoassalLayouts/actions/workflows/runTests.yml)
55
![Discord](https://img.shields.io/discord/223421264751099906)
66

7-
[![Pharo 8](https://img.shields.io/badge/Pharo-8.0-%23aac9ff.svg)](https://pharo.org/download)
87
[![Pharo 9](https://img.shields.io/badge/Pharo-9.0-%23aac9ff.svg)](https://pharo.org/download)
98
[![Pharo 10](https://img.shields.io/badge/Pharo-10-%23aac9ff.svg)](https://pharo.org/download)
109
[![Pharo 11](https://img.shields.io/badge/Pharo-11-%23aac9ff.svg)](https://pharo.org/download)
1110
[![Pharo 12](https://img.shields.io/badge/Pharo-12-%23aac9ff.svg)](https://pharo.org/download)
11+
[![Pharo 13](https://img.shields.io/badge/Pharo-13-%23aac9ff.svg)](https://pharo.org/download)
1212

1313
[*Chat with us on #Roassal*](https://discord.gg/QewZMZa)
1414

src/BaselineOfRoassalLayouts/BaselineOfRoassalLayouts.class.st

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,13 @@ Based on roassal
33
https://github.com/ObjectProfile/Roassal3
44
"
55
Class {
6-
#name : #BaselineOfRoassalLayouts,
7-
#superclass : #BaselineOf,
8-
#category : #BaselineOfRoassalLayouts
6+
#name : 'BaselineOfRoassalLayouts',
7+
#superclass : 'BaselineOf',
8+
#category : 'BaselineOfRoassalLayouts',
9+
#package : 'BaselineOfRoassalLayouts'
910
}
1011

11-
{ #category : #baselines }
12+
{ #category : 'baselines' }
1213
BaselineOfRoassalLayouts >> baseline: spec [
1314
<baseline>
1415
spec for: #common do: [
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Package { #name : #BaselineOfRoassalLayouts }
1+
Package { #name : 'BaselineOfRoassalLayouts' }

src/Roassal-Layouts-Tests/ManifestRoassalLayoutsTests.class.st

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@
22
Please describe the package using the class comment of the included manifest class. The manifest class also includes other additional metadata for the package. These meta data are used by other tools such as the SmalllintManifestChecker and the critics Browser
33
"
44
Class {
5-
#name : #ManifestRoassalLayoutsTests,
6-
#superclass : #PackageManifest,
7-
#category : 'Roassal-Layouts-Tests-Manifest'
5+
#name : 'ManifestRoassalLayoutsTests',
6+
#superclass : 'PackageManifest',
7+
#category : 'Roassal-Layouts-Tests-Manifest',
8+
#package : 'Roassal-Layouts-Tests',
9+
#tag : 'Manifest'
810
}

src/Roassal-Layouts-Tests/RSAlignmentTest.class.st

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,20 @@
11
Class {
2-
#name : #RSAlignmentTest,
3-
#superclass : #TestCase,
2+
#name : 'RSAlignmentTest',
3+
#superclass : 'TestCase',
44
#instVars : [
55
'align'
66
],
7-
#category : 'Roassal-Layouts-Tests'
7+
#category : 'Roassal-Layouts-Tests',
8+
#package : 'Roassal-Layouts-Tests'
89
}
910

10-
{ #category : #running }
11+
{ #category : 'running' }
1112
RSAlignmentTest >> setUp [
1213
super setUp.
1314
align := RSAlignment new
1415
]
1516

16-
{ #category : #tests }
17+
{ #category : 'tests' }
1718
RSAlignmentTest >> testCenter [
1819
| es |
1920
es := (1 to: 5) collect: [ :v | RSLayoutNode new size: 10 ] as: RSGroup.
@@ -23,7 +24,7 @@ RSAlignmentTest >> testCenter [
2324
self assert: es encompassingRectangle equals: ((0.0@0.0) corner: (70.0@10.0))
2425
]
2526

26-
{ #category : #tests }
27+
{ #category : 'tests' }
2728
RSAlignmentTest >> testFromBottom [
2829
| es |
2930
es := (10 to: 100 by: 10) collect: [ :n | RSLayoutNode new size: n; yourself ].
@@ -36,7 +37,7 @@ RSAlignmentTest >> testFromBottom [
3637
self assert: (es collect: [ :e | e encompassingRectangle bottom ]) asArray equals: #(170.0 170.0 170.0 170.0 170.0 170.0 170.0 170.0 170.0 170.0)
3738
]
3839

39-
{ #category : #tests }
40+
{ #category : 'tests' }
4041
RSAlignmentTest >> testFromLeft [
4142
| es |
4243
es := (10 to: 100 by: 10) collect: [ :n | RSLayoutNode new size: n; yourself ].
@@ -49,7 +50,7 @@ RSAlignmentTest >> testFromLeft [
4950
self assert: (es collect: [ :e | e encompassingRectangle left ]) asArray equals: #(-150.0 -150.0 -150.0 -150.0 -150.0 -150.0 -150.0 -150.0 -150.0 -150.0)
5051
]
5152

52-
{ #category : #tests }
53+
{ #category : 'tests' }
5354
RSAlignmentTest >> testFromLeftWithAFixShape [
5455
| es |
5556
es := (10 to: 100 by: 10) collect: [ :n | RSLayoutNode new size: n; yourself ].
@@ -61,7 +62,7 @@ RSAlignmentTest >> testFromLeftWithAFixShape [
6162
self assert: (es collect: [ :e | e encompassingRectangle left ]) asArray equals: #(0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0)
6263
]
6364

64-
{ #category : #tests }
65+
{ #category : 'tests' }
6566
RSAlignmentTest >> testFromLeftWithFixedShape [
6667
| es c |
6768
es := (10 to: 100 by: 10) collect: [ :n | RSLayoutNode new size: n; yourself ].
@@ -79,7 +80,7 @@ RSAlignmentTest >> testFromLeftWithFixedShape [
7980
self assert: (es collect: [ :e | e encompassingRectangle left ]) asArray equals: #(-150.0 -150.0 -150.0 -150.0 -150.0 -150.0 -150.0 -150.0 -150.0 -150.0)
8081
]
8182

82-
{ #category : #tests }
83+
{ #category : 'tests' }
8384
RSAlignmentTest >> testFromRight [
8485
| es |
8586
es := (10 to: 100 by: 10) collect: [ :n | RSLayoutNode new size: n; yourself ].
@@ -92,7 +93,7 @@ RSAlignmentTest >> testFromRight [
9293
self assert: (es collect: [ :e | e encompassingRectangle right ]) asArray equals: #(170.0 170.0 170.0 170.0 170.0 170.0 170.0 170.0 170.0 170.0)
9394
]
9495

95-
{ #category : #tests }
96+
{ #category : 'tests' }
9697
RSAlignmentTest >> testFromTop [
9798
| es |
9899
es := (10 to: 100 by: 10) collect: [ :n | RSLayoutNode new size: n; yourself ].
@@ -105,7 +106,7 @@ RSAlignmentTest >> testFromTop [
105106
self assert: (es collect: [ :e | e encompassingRectangle top ]) asArray equals: #(-50.0 -50.0 -50.0 -50.0 -50.0 -50.0 -50.0 -50.0 -50.0 -50.0)
106107
]
107108

108-
{ #category : #tests }
109+
{ #category : 'tests' }
109110
RSAlignmentTest >> testFromTopWithAFixShape [
110111
| es |
111112
es := (10 to: 100 by: 10) collect: [ :n | RSLayoutNode new size: n; yourself ].
@@ -120,7 +121,7 @@ RSAlignmentTest >> testFromTopWithAFixShape [
120121
self assert: (es collect: [ :e | e encompassingRectangle top ]) asArray equals: #(0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0)
121122
]
122123

123-
{ #category : #tests }
124+
{ #category : 'tests' }
124125
RSAlignmentTest >> testHasElement [
125126
self deny: align hasShape.
126127
align shapes: (Array with: RSLayoutNode new).
@@ -129,7 +130,7 @@ RSAlignmentTest >> testHasElement [
129130
self deny: align hasShape
130131
]
131132

132-
{ #category : #tests }
133+
{ #category : 'tests' }
133134
RSAlignmentTest >> testNoErrorOnDefault [
134135

135136
RSAlignment new left; right; top; bottom

src/Roassal-Layouts-Tests/RSAngleLineLayoutTest.class.st

Lines changed: 15 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,17 @@
11
Class {
2-
#name : #RSAngleLineLayoutTest,
3-
#superclass : #RSLayoutTest,
4-
#category : 'Roassal-Layouts-Tests'
2+
#name : 'RSAngleLineLayoutTest',
3+
#superclass : 'RSLayoutTest',
4+
#category : 'Roassal-Layouts-Tests',
5+
#package : 'Roassal-Layouts-Tests'
56
}
67

7-
{ #category : #tests }
8+
{ #category : 'utilities' }
9+
RSAngleLineLayoutTest >> apply [
10+
11+
RSAngleLineLayout new on: shapes
12+
]
13+
14+
{ #category : 'tests' }
815
RSAngleLineLayoutTest >> testBasic [
916

1017
| layout angle |
@@ -15,7 +22,7 @@ RSAngleLineLayoutTest >> testBasic [
1522
self assert: layout angle equals: angle
1623
]
1724

18-
{ #category : #tests }
25+
{ #category : 'tests' }
1926
RSAngleLineLayoutTest >> testGapSize [
2027

2128
| layout var1st var2nd |
@@ -27,7 +34,7 @@ RSAngleLineLayoutTest >> testGapSize [
2734
self assert: var2nd position closeTo: 107.5 @ 2.5
2835
]
2936

30-
{ #category : #tests }
37+
{ #category : 'tests' }
3138
RSAngleLineLayoutTest >> testLayoutWith0Angle [
3239

3340
| layout x gap |
@@ -40,7 +47,7 @@ RSAngleLineLayoutTest >> testLayoutWith0Angle [
4047
x := x + each width + gap ]
4148
]
4249

43-
{ #category : #tests }
50+
{ #category : 'tests' }
4451
RSAngleLineLayoutTest >> testLayoutWith90Angle [
4552

4653
| layout y gap |
@@ -54,7 +61,7 @@ RSAngleLineLayoutTest >> testLayoutWith90Angle [
5461
y := y + each height + gap ]
5562
]
5663

57-
{ #category : #tests }
64+
{ #category : 'tests' }
5865
RSAngleLineLayoutTest >> testLayoutWithThreeElements [
5966
| layout gap extent |
6067
layout := RSAngleLineLayout new.

src/Roassal-Layouts-Tests/RSCircularAroundAVertexLayoutTest.class.st

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,19 @@
22
A RSCircularAroundAVertexLayoutTest is a test class for testing the behavior of RSCircularAroundAVertexLayout
33
"
44
Class {
5-
#name : #RSCircularAroundAVertexLayoutTest,
6-
#superclass : #RSLayoutTest,
7-
#category : 'Roassal-Layouts-Tests'
5+
#name : 'RSCircularAroundAVertexLayoutTest',
6+
#superclass : 'RSLayoutTest',
7+
#category : 'Roassal-Layouts-Tests',
8+
#package : 'Roassal-Layouts-Tests'
89
}
910

10-
{ #category : #tests }
11+
{ #category : 'utilities' }
12+
RSCircularAroundAVertexLayoutTest >> apply [
13+
14+
RSCircularAroundAVertexLayout new on: canvas nodes
15+
]
16+
17+
{ #category : 'tests' }
1118
RSCircularAroundAVertexLayoutTest >> testApplyDefaultLayoutOverlapsShapes [
1219
| layout first second |
1320
layout := RSCircularAroundAVertexLayout new.
@@ -18,7 +25,7 @@ RSCircularAroundAVertexLayoutTest >> testApplyDefaultLayoutOverlapsShapes [
1825
self deny: first position equals: second position
1926
]
2027

21-
{ #category : #tests }
28+
{ #category : 'tests' }
2229
RSCircularAroundAVertexLayoutTest >> testApplyLayoutShouldChangeOldPositions [
2330
| layout oldPositions |
2431
layout := RSCircularAroundAVertexLayout new.
@@ -27,7 +34,7 @@ RSCircularAroundAVertexLayoutTest >> testApplyLayoutShouldChangeOldPositions [
2734
self deny: (canvas nodes collect: #position) equals: oldPositions
2835
]
2936

30-
{ #category : #tests }
37+
{ #category : 'tests' }
3138
RSCircularAroundAVertexLayoutTest >> testRadius [
3239
| layout boundingBox |
3340
layout := RSCircularAroundAVertexLayout new.

src/Roassal-Layouts-Tests/RSClusteringLayoutTest.class.st

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
Class {
2-
#name : #RSClusteringLayoutTest,
3-
#superclass : #RSLayoutTestCase,
4-
#category : 'Roassal-Layouts-Tests'
2+
#name : 'RSClusteringLayoutTest',
3+
#superclass : 'RSLayoutTestCase',
4+
#category : 'Roassal-Layouts-Tests',
5+
#package : 'Roassal-Layouts-Tests'
56
}
67

7-
{ #category : #tests }
8+
{ #category : 'tests' }
89
RSClusteringLayoutTest >> testBasic [
910

1011
| c shapes lb nodes |
@@ -70,7 +71,7 @@ RSClusteringLayoutTest >> testBasic [
7071
144 @ 65.}
7172
]
7273

73-
{ #category : #tests }
74+
{ #category : 'tests' }
7475
RSClusteringLayoutTest >> testBasic2 [
7576

7677
| shapes c lb nodes clusters |
@@ -90,7 +91,7 @@ RSClusteringLayoutTest >> testBasic2 [
9091
self assert: clusters size equals: 10
9192
]
9293

93-
{ #category : #tests }
94+
{ #category : 'tests' }
9495
RSClusteringLayoutTest >> testBasic3 [
9596

9697
| c shapes lb nodes clusters |
@@ -110,7 +111,7 @@ RSClusteringLayoutTest >> testBasic3 [
110111
self assert: clusters size equals: 1
111112
]
112113

113-
{ #category : #tests }
114+
{ #category : 'tests' }
114115
RSClusteringLayoutTest >> testCycles [
115116
| chars canvas shapes |
116117
canvas := RSLayoutNode new.
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
"
2+
A RSDominanceTreeLayoutTest is a test class for testing the behavior of RSDominanceTreeLayout
3+
"
4+
Class {
5+
#name : 'RSDominanceTreeLayoutTest',
6+
#superclass : 'RSLayoutTest',
7+
#category : 'Roassal-Layouts-Tests',
8+
#package : 'Roassal-Layouts-Tests'
9+
}
10+
11+
{ #category : 'utilities' }
12+
RSDominanceTreeLayoutTest >> apply [
13+
14+
RSDominanceTreeLayout new on: shapes
15+
]

0 commit comments

Comments
 (0)