Skip to content

Commit

Permalink
Merge 2ffa3d0
Browse files Browse the repository at this point in the history
  • Loading branch information
JanBliznicenko committed Nov 15, 2024
2 parents ebd2d4e + 2ffa3d0 commit 66a9078
Show file tree
Hide file tree
Showing 57 changed files with 1,262 additions and 581 deletions.
12 changes: 5 additions & 7 deletions .smalltalk.ston
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ SmalltalkCISpec {
#platforms : [
#pharo
],
#baseline : 'ClassEditor',
#baseline : 'OpenPonkClassEditor',
#directory : 'repository',
#onConflict : #useIncoming,
#load : [ 'complete' ]
Expand All @@ -13,15 +13,13 @@ SmalltalkCISpec {
#preLoading : 'ci-scripts/.github/scripts/preLoad.st',
#postLoading : 'ci-scripts/.github/scripts/postLoad.st',
#testing : {
#packages : [
'OpenPonk*'
],
#coverage : {
#packages : [
'OpenPonk-ClassEditor*'
]
},
#packages : [
'OpenPonk*',
'OP-*',
'OntoUML*'
]
}
}
}
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

```smalltalk
Metacello new
baseline: 'ClassEditor';
baseline: 'OpenPonkClassEditor';
repository: 'github://OpenPonk/class-editor/repository';
load: 'complete'.
```
Expand Down
78 changes: 0 additions & 78 deletions repository/BaselineOfClassEditor/BaselineOfClassEditor.class.st

This file was deleted.

1 change: 0 additions & 1 deletion repository/BaselineOfClassEditor/package.st

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
"
Baseline for https://github.com/OpenPonk/class-editor
"
Class {
#name : 'BaselineOfOpenPonkClassEditor',
#superclass : 'BaselineOf',
#category : 'BaselineOfOpenPonkClassEditor',
#package : 'BaselineOfOpenPonkClassEditor'
}

{ #category : 'plugins' }
BaselineOfOpenPonkClassEditor class >> loadPlugins [
self new loadPlugins
]

{ #category : 'baselines' }
BaselineOfOpenPonkClassEditor >> baseline: spec [

<baseline>
spec for: #common do: [
spec
baseline: 'OpenPonkUMLXMI'
with: [ spec repository: 'github://openponk/uml-xmi' ].
spec
baseline: 'OpenPonkUMLBootstrapGenerator'
with: [
spec repository: 'github://openponk/uml-bootstrap-generator' ].
spec
baseline: 'OpenPonk'
with: [ spec repository: 'github://openponk/openponk' ].
spec
baseline: 'OpenPonkUMLProfiles'
with: [ spec repository: 'github://openponk/uml-profiles' ].
spec package: 'OpenPonk-ClassEditor' with: [
spec requires: #( 'OpenPonkUMLXMI' 'OpenPonkUMLBootstrapGenerator'
'OpenPonkUMLProfiles' ) ].

spec group: 'plugin' with: #( 'OpenPonk-ClassEditor' ).
(Smalltalk globals includesKey:
#BaselineOfOpenPonkOntoUMLVerifications)
ifTrue: [ spec group: 'complete-plugin' with: #( plugin ) ]
ifFalse: [
self plugins: spec.
spec package: 'OpenPonk-ClassEditor-Plugins' with: [
spec requires:
#( 'OpenPonkOntoUMLVerifications' OpenPonkOntoUMLPatterns
OpenPonkGit OpenPonkOntoUMLTransformations ) ].
spec
group: 'complete-plugin'
with: #( plugin 'OpenPonk-ClassEditor-Plugins' ) ].
spec group: 'complete' with: #( OpenPonk 'complete-plugin' ).
spec group: 'default' with: #( OpenPonk plugin ) ]
]

{ #category : 'baselines' }
BaselineOfOpenPonkClassEditor >> plugins: spec [

spec baseline: 'OpenPonkOntoUMLVerifications' with: [
spec
repository: 'github://openponk/ontouml-verifications';
loads: 'plugin' ].
spec baseline: 'OpenPonkOntoUMLTransformations' with: [
spec
repository:
'github://openponk/openponk-ontouml-to-uml-transformation';
loads: 'plugin' ].
spec
baseline: 'OpenPonkGit'
with: [ spec repository: 'github://openponk/openponk-git' ].
spec baseline: 'OpenPonkOntoUMLPatterns' with: [
spec
repository: 'github://openponk/ontouml-patterns';
loads: 'plugin' ]
]
1 change: 1 addition & 0 deletions repository/BaselineOfOpenPonkClassEditor/package.st
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Package { #name : 'BaselineOfOpenPonkClassEditor' }

This file was deleted.

1 change: 0 additions & 1 deletion repository/OPClassEditor-Plugins/package.st

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Class {
#name : 'OPClassEditorPluginsMeta',
#superclass : 'Object',
#category : 'OpenPonk-ClassEditor-Plugins',
#package : 'OpenPonk-ClassEditor-Plugins'
}
1 change: 1 addition & 0 deletions repository/OpenPonk-ClassEditor-Plugins/package.st
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Package { #name : 'OpenPonk-ClassEditor-Plugins' }
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
Class {
#name : 'OPUmlCompartmentableShapeTest',
#name : 'OPAbstractUmlCompartmentableShapeTest',
#superclass : 'OPAbstractUmlShapeTest',
#category : 'OpenPonk-ClassEditor-Tests - Shapes',
#package : 'OpenPonk-ClassEditor',
#tag : 'Tests - Shapes'
}

{ #category : 'hooks' }
OPUmlCompartmentableShapeTest >> shapeClass [
OPAbstractUmlCompartmentableShapeTest >> shapeClass [
^ OPUmlCompartmentableShape
]

{ #category : 'tests' }
OPUmlCompartmentableShapeTest >> testEmptyRoassalShape [
OPAbstractUmlCompartmentableShapeTest >> testEmptyRoassalShape [

| roassalShape |
shape renderIn: RSCanvas new.
Expand All @@ -21,15 +21,15 @@ OPUmlCompartmentableShapeTest >> testEmptyRoassalShape [
]

{ #category : 'tests' }
OPUmlCompartmentableShapeTest >> testFigures [
OPAbstractUmlCompartmentableShapeTest >> testFigures [

shape renderIn: RSCanvas new.

self assert: shape canvas nodes isNotEmpty
]

{ #category : 'tests' }
OPUmlCompartmentableShapeTest >> testFigures1 [
OPAbstractUmlCompartmentableShapeTest >> testFigures1 [

| lbl |
(lbl := OPUmlLabel new) owningElement: shape.
Expand All @@ -38,7 +38,7 @@ OPUmlCompartmentableShapeTest >> testFigures1 [
]

{ #category : 'tests' }
OPUmlCompartmentableShapeTest >> testFigures2 [
OPAbstractUmlCompartmentableShapeTest >> testFigures2 [

| lbl comp1 |
(lbl := OPUmlLabel new) owningElement: shape.
Expand All @@ -52,7 +52,7 @@ OPUmlCompartmentableShapeTest >> testFigures2 [
]

{ #category : 'tests' }
OPUmlCompartmentableShapeTest >> testFigures3 [
OPAbstractUmlCompartmentableShapeTest >> testFigures3 [

| lbl comp compLbl |
(lbl := OPUmlLabel new) owningElement: shape.
Expand All @@ -65,18 +65,16 @@ OPUmlCompartmentableShapeTest >> testFigures3 [
]

{ #category : 'tests' }
OPUmlCompartmentableShapeTest >> testRemoveExtentChanged [
OPAbstractUmlCompartmentableShapeTest >> testRemoveExtentChanged [

| compartment compLbl canvas fullExtent labelContainer |
shape modelElement: OPTestEntityModel new.
| compartment compLbl fullExtent labelContainer |
labelContainer := OPUmlCompartmentableLabel in: shape.
OPUmlNameLabel in: labelContainer.
compartment := OPUmlCompartment in: shape.
5 timesRepeat: [
compLbl := (OPUmlLabel in: compartment)
text: 'testx';
yourself ].
canvas := RSCanvas new.
shape renderIn: canvas.
fullExtent := shape extent.
compLbl remove.
Expand All @@ -85,7 +83,7 @@ OPUmlCompartmentableShapeTest >> testRemoveExtentChanged [
]

{ #category : 'tests' }
OPUmlCompartmentableShapeTest >> testRemoveFromOwnership [
OPAbstractUmlCompartmentableShapeTest >> testRemoveFromOwnership [

| lbl |
(lbl := OPUmlLabel new) owningElement: shape.
Expand All @@ -97,7 +95,7 @@ OPUmlCompartmentableShapeTest >> testRemoveFromOwnership [
]

{ #category : 'tests' }
OPUmlCompartmentableShapeTest >> testRemoveFromViewEmpty [
OPAbstractUmlCompartmentableShapeTest >> testRemoveFromViewEmpty [

| canvas |
canvas := RSCanvas new.
Expand All @@ -107,7 +105,7 @@ OPUmlCompartmentableShapeTest >> testRemoveFromViewEmpty [
]

{ #category : 'tests' }
OPUmlCompartmentableShapeTest >> testRemoveOwnedElement [
OPAbstractUmlCompartmentableShapeTest >> testRemoveOwnedElement [

| lbl |
(lbl := OPUmlLabel new) owningElement: shape.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
Class {
#name : 'OPUmlEdgeTest',
#name : 'OPAbstractUmlEdgeTest',
#superclass : 'OPAbstractEdgeTest',
#category : 'OpenPonk-ClassEditor-Tests - Shapes',
#package : 'OpenPonk-ClassEditor',
#tag : 'Tests - Shapes'
}

{ #category : 'running' }
OPUmlEdgeTest >> setUp [
OPAbstractUmlEdgeTest >> setUp [
| source target |
super setUp.
source := OPUmlLabel new.
Expand All @@ -19,12 +19,12 @@ OPUmlEdgeTest >> setUp [
]

{ #category : 'hooks' }
OPUmlEdgeTest >> shapeClass [
OPAbstractUmlEdgeTest >> shapeClass [
^ OPUmlEdge
]

{ #category : 'tests' }
OPUmlEdgeTest >> testRemove [
OPAbstractUmlEdgeTest >> testRemove [

| lbl |
(lbl := OPUmlLabel new) owningElement: shape.
Expand All @@ -34,7 +34,7 @@ OPUmlEdgeTest >> testRemove [
]

{ #category : 'tests' }
OPUmlEdgeTest >> testRemoveDetachFromEnds [
OPAbstractUmlEdgeTest >> testRemoveDetachFromEnds [

| source target |
source := OPUmlLabel new.
Expand All @@ -47,9 +47,10 @@ OPUmlEdgeTest >> testRemoveDetachFromEnds [
]

{ #category : 'tests' }
OPUmlEdgeTest >> testRemoveFromView [
OPAbstractUmlEdgeTest >> testRemoveFromView [

| lbl |
shape modelElement: model.
(lbl := OPUmlLabel new)
text: 'x';
owningElement: shape.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Class {
#name : 'OPAbstractUmlShapeTest',
#superclass : 'OPAbstractShapeTest',
#superclass : 'OPAbstractNodeTest',
#category : 'OpenPonk-ClassEditor-Tests - Shapes',
#package : 'OpenPonk-ClassEditor',
#tag : 'Tests - Shapes'
Expand Down Expand Up @@ -48,7 +48,7 @@ OPAbstractUmlShapeTest >> testAddSelfEdge [

{ #category : 'tests' }
OPAbstractUmlShapeTest >> testEmpty [
self assert: shape modelElement isNil.
super testEmpty.
self assert: shape owningElement doesNotExist.
self assert: shape ownedElements isEmpty.
self assert: shape sourceEdges isEmpty.
Expand Down
8 changes: 8 additions & 0 deletions repository/OpenPonk-ClassEditor/OPDiagram.extension.st
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
Extension { #name : 'OPDiagram' }

{ #category : '*OpenPonk-ClassEditor' }
OPDiagram >> supportsHidingLabelEnds [

^ self modelElement isNotNil and: [
self modelElement isKindOf: OPUMLPackage ]
]
Loading

0 comments on commit 66a9078

Please sign in to comment.