Skip to content

Commit 0a9d1ba

Browse files
Merge pull request #77 from moosetechnology/76-Generate-testing-methods
Fix #76: add testing methods
2 parents f65942a + b1541b0 commit 0a9d1ba

32 files changed

Lines changed: 434 additions & 231 deletions

src/FAST-Core-Model/FASTEntity.class.st

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,16 @@ any entity
1111
1212
"
1313
Class {
14-
#name : #FASTEntity,
15-
#superclass : #MooseEntity,
14+
#name : 'FASTEntity',
15+
#superclass : 'MooseEntity',
1616
#traits : 'FASTTEntity',
1717
#classTraits : 'FASTTEntity classTrait',
18-
#category : #'FAST-Core-Model-Entities'
18+
#category : 'FAST-Core-Model-Entities',
19+
#package : 'FAST-Core-Model',
20+
#tag : 'Entities'
1921
}
2022

21-
{ #category : #meta }
23+
{ #category : 'meta' }
2224
FASTEntity class >> annotation [
2325

2426
<FMClass: #Entity super: #MooseEntity>
@@ -27,14 +29,14 @@ FASTEntity class >> annotation [
2729
^ self
2830
]
2931

30-
{ #category : #meta }
32+
{ #category : 'meta' }
3133
FASTEntity class >> metamodel [
3234

3335
<generated>
3436
^ FASTModel metamodel
3537
]
3638

37-
{ #category : #testing }
39+
{ #category : 'testing' }
3840
FASTEntity >> isQueryable [
3941

4042
<generated>

src/FAST-Core-Model/FASTModel.class.st

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,20 @@
11
Class {
2-
#name : #FASTModel,
3-
#superclass : #MooseModel,
2+
#name : 'FASTModel',
3+
#superclass : 'MooseModel',
44
#traits : 'FASTTEntityCreator',
55
#classTraits : 'FASTTEntityCreator classTrait',
6-
#category : #'FAST-Core-Model-Model'
6+
#category : 'FAST-Core-Model-Model',
7+
#package : 'FAST-Core-Model',
8+
#tag : 'Model'
79
}
810

9-
{ #category : #accessing }
11+
{ #category : 'accessing' }
1012
FASTModel class >> allSubmetamodelsPackagesNames [
1113
<generated>
1214
^ #(#'Moose-Query' #'Famix-Traits')
1315
]
1416

15-
{ #category : #meta }
17+
{ #category : 'meta' }
1618
FASTModel class >> annotation [
1719
<FMClass: #FASTModel super: #MooseModel>
1820
<package: #'FAST-Core-Model'>

src/FAST-Core-Model/FASTTAssignment.trait.st

Lines changed: 18 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -32,17 +32,19 @@ A node representing an assignment
3232
3333
"
3434
Trait {
35-
#name : #FASTTAssignment,
35+
#name : 'FASTTAssignment',
3636
#instVars : [
3737
'#expression => FMOne type: #FASTTExpression opposite: #assignedIn',
3838
'#variable => FMOne type: #FASTTVariableEntity opposite: #parentAssignmentExpression'
3939
],
4040
#traits : 'FASTTExpression',
4141
#classTraits : 'FASTTExpression classTrait',
42-
#category : #'FAST-Core-Model-Traits'
42+
#category : 'FAST-Core-Model-Traits',
43+
#package : 'FAST-Core-Model',
44+
#tag : 'Traits'
4345
}
4446

45-
{ #category : #meta }
47+
{ #category : 'meta' }
4648
FASTTAssignment classSide >> annotation [
4749

4850
<FMClass: #TAssignment super: #Object>
@@ -51,7 +53,7 @@ FASTTAssignment classSide >> annotation [
5153
^ self
5254
]
5355

54-
{ #category : #accessing }
56+
{ #category : 'accessing' }
5557
FASTTAssignment >> expression [
5658
"Relation named: #expression type: #FASTTExpression opposite: #assignedIn"
5759

@@ -60,21 +62,28 @@ FASTTAssignment >> expression [
6062
^ expression
6163
]
6264

63-
{ #category : #accessing }
65+
{ #category : 'accessing' }
6466
FASTTAssignment >> expression: anObject [
6567

6668
<generated>
6769
expression := anObject
6870
]
6971

70-
{ #category : #navigation }
72+
{ #category : 'navigation' }
7173
FASTTAssignment >> expressionGroup [
7274
<generated>
7375
<navigation: 'Expression'>
7476
^ MooseSpecializedGroup with: self expression
7577
]
7678

77-
{ #category : #accessing }
79+
{ #category : 'testing' }
80+
FASTTAssignment >> isAssignment [
81+
82+
<generated>
83+
^ true
84+
]
85+
86+
{ #category : 'accessing' }
7887
FASTTAssignment >> variable [
7988
"Relation named: #variable type: #FASTTVariableEntity opposite: #parentAssignmentExpression"
8089

@@ -83,14 +92,14 @@ FASTTAssignment >> variable [
8392
^ variable
8493
]
8594

86-
{ #category : #accessing }
95+
{ #category : 'accessing' }
8796
FASTTAssignment >> variable: anObject [
8897

8998
<generated>
9099
variable := anObject
91100
]
92101

93-
{ #category : #navigation }
102+
{ #category : 'navigation' }
94103
FASTTAssignment >> variableGroup [
95104
<generated>
96105
<navigation: 'Variable'>

src/FAST-Core-Model/FASTTBehaviouralEntity.trait.st

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,16 +27,18 @@ Local variables are intended to be stored in the local entities of the body
2727
2828
"
2929
Trait {
30-
#name : #FASTTBehaviouralEntity,
30+
#name : 'FASTTBehaviouralEntity',
3131
#instVars : [
3232
'#statementBlock => FMOne type: #FASTTStatementBlock opposite: #fastBehaviouralParent'
3333
],
3434
#traits : 'FASTTScopableEntity + FASTTWithParameters',
3535
#classTraits : 'FASTTScopableEntity classTrait + FASTTWithParameters classTrait',
36-
#category : #'FAST-Core-Model-Traits'
36+
#category : 'FAST-Core-Model-Traits',
37+
#package : 'FAST-Core-Model',
38+
#tag : 'Traits'
3739
}
3840

39-
{ #category : #meta }
41+
{ #category : 'meta' }
4042
FASTTBehaviouralEntity classSide >> annotation [
4143

4244
<FMClass: #TBehaviouralEntity super: #Object>
@@ -45,7 +47,14 @@ FASTTBehaviouralEntity classSide >> annotation [
4547
^ self
4648
]
4749

48-
{ #category : #accessing }
50+
{ #category : 'testing' }
51+
FASTTBehaviouralEntity >> isBehaviouralEntity [
52+
53+
<generated>
54+
^ true
55+
]
56+
57+
{ #category : 'accessing' }
4958
FASTTBehaviouralEntity >> statementBlock [
5059
"Relation named: #statementBlock type: #FASTTStatementBlock opposite: #fastBehaviouralParent"
5160

@@ -54,14 +63,14 @@ FASTTBehaviouralEntity >> statementBlock [
5463
^ statementBlock
5564
]
5665

57-
{ #category : #accessing }
66+
{ #category : 'accessing' }
5867
FASTTBehaviouralEntity >> statementBlock: anObject [
5968

6069
<generated>
6170
statementBlock := anObject
6271
]
6372

64-
{ #category : #navigation }
73+
{ #category : 'navigation' }
6574
FASTTBehaviouralEntity >> statementBlockGroup [
6675
<generated>
6776
<navigation: 'StatementBlock'>

src/FAST-Core-Model/FASTTBinaryExpression.trait.st

Lines changed: 20 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -33,18 +33,20 @@ A trait representing a binary expression of a node of a source code.
3333
3434
"
3535
Trait {
36-
#name : #FASTTBinaryExpression,
36+
#name : 'FASTTBinaryExpression',
3737
#instVars : [
3838
'#leftOperand => FMOne type: #FASTTExpression opposite: #parentExpressionLeft',
3939
'#operator => FMProperty',
4040
'#rightOperand => FMOne type: #FASTTExpression opposite: #parentExpressionRight'
4141
],
4242
#traits : 'FASTTExpression',
4343
#classTraits : 'FASTTExpression classTrait',
44-
#category : #'FAST-Core-Model-Traits'
44+
#category : 'FAST-Core-Model-Traits',
45+
#package : 'FAST-Core-Model',
46+
#tag : 'Traits'
4547
}
4648

47-
{ #category : #meta }
49+
{ #category : 'meta' }
4850
FASTTBinaryExpression classSide >> annotation [
4951

5052
<FMClass: #TBinaryExpression super: #Object>
@@ -53,7 +55,14 @@ FASTTBinaryExpression classSide >> annotation [
5355
^ self
5456
]
5557

56-
{ #category : #accessing }
58+
{ #category : 'testing' }
59+
FASTTBinaryExpression >> isBinaryExpression [
60+
61+
<generated>
62+
^ true
63+
]
64+
65+
{ #category : 'accessing' }
5766
FASTTBinaryExpression >> leftOperand [
5867
"Relation named: #leftOperand type: #FASTTExpression opposite: #parentExpressionLeft"
5968

@@ -62,21 +71,21 @@ FASTTBinaryExpression >> leftOperand [
6271
^ leftOperand
6372
]
6473

65-
{ #category : #accessing }
74+
{ #category : 'accessing' }
6675
FASTTBinaryExpression >> leftOperand: anObject [
6776

6877
<generated>
6978
leftOperand := anObject
7079
]
7180

72-
{ #category : #navigation }
81+
{ #category : 'navigation' }
7382
FASTTBinaryExpression >> leftOperandGroup [
7483
<generated>
7584
<navigation: 'LeftOperand'>
7685
^ MooseSpecializedGroup with: self leftOperand
7786
]
7887

79-
{ #category : #accessing }
88+
{ #category : 'accessing' }
8089
FASTTBinaryExpression >> operator [
8190

8291
<FMProperty: #operator type: #String>
@@ -85,13 +94,13 @@ FASTTBinaryExpression >> operator [
8594
^ operator
8695
]
8796

88-
{ #category : #accessing }
97+
{ #category : 'accessing' }
8998
FASTTBinaryExpression >> operator: anObject [
9099
<generated>
91100
operator := anObject
92101
]
93102

94-
{ #category : #accessing }
103+
{ #category : 'accessing' }
95104
FASTTBinaryExpression >> rightOperand [
96105
"Relation named: #rightOperand type: #FASTTExpression opposite: #parentExpressionRight"
97106

@@ -100,14 +109,14 @@ FASTTBinaryExpression >> rightOperand [
100109
^ rightOperand
101110
]
102111

103-
{ #category : #accessing }
112+
{ #category : 'accessing' }
104113
FASTTBinaryExpression >> rightOperand: anObject [
105114

106115
<generated>
107116
rightOperand := anObject
108117
]
109118

110-
{ #category : #navigation }
119+
{ #category : 'navigation' }
111120
FASTTBinaryExpression >> rightOperandGroup [
112121
<generated>
113122
<navigation: 'RightOperand'>

src/FAST-Core-Model/FASTTBooleanLiteral.trait.st

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,17 +27,26 @@ A boolean literal
2727
2828
"
2929
Trait {
30-
#name : #FASTTBooleanLiteral,
30+
#name : 'FASTTBooleanLiteral',
3131
#traits : 'FASTTLiteral',
3232
#classTraits : 'FASTTLiteral classTrait',
33-
#category : #'FAST-Core-Model-Traits'
33+
#category : 'FAST-Core-Model-Traits',
34+
#package : 'FAST-Core-Model',
35+
#tag : 'Traits'
3436
}
3537

36-
{ #category : #meta }
38+
{ #category : 'meta' }
3739
FASTTBooleanLiteral classSide >> annotation [
3840

3941
<FMClass: #TBooleanLiteral super: #Object>
4042
<package: #'FAST-Core-Model'>
4143
<generated>
4244
^ self
4345
]
46+
47+
{ #category : 'testing' }
48+
FASTTBooleanLiteral >> isBooleanLiteral [
49+
50+
<generated>
51+
^ true
52+
]

src/FAST-Core-Model/FASTTCharacterLiteral.trait.st

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,17 +27,26 @@ A character literal
2727
2828
"
2929
Trait {
30-
#name : #FASTTCharacterLiteral,
30+
#name : 'FASTTCharacterLiteral',
3131
#traits : 'FASTTLiteral',
3232
#classTraits : 'FASTTLiteral classTrait',
33-
#category : #'FAST-Core-Model-Traits'
33+
#category : 'FAST-Core-Model-Traits',
34+
#package : 'FAST-Core-Model',
35+
#tag : 'Traits'
3436
}
3537

36-
{ #category : #meta }
38+
{ #category : 'meta' }
3739
FASTTCharacterLiteral classSide >> annotation [
3840

3941
<FMClass: #TCharacterLiteral super: #Object>
4042
<package: #'FAST-Core-Model'>
4143
<generated>
4244
^ self
4345
]
46+
47+
{ #category : 'testing' }
48+
FASTTCharacterLiteral >> isCharacterLiteral [
49+
50+
<generated>
51+
^ true
52+
]

0 commit comments

Comments
 (0)