Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use a test resource to compile less classes #114

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
accessing
resources

^ { TonelTestResource }
Original file line number Diff line number Diff line change
@@ -1,12 +1,4 @@
utils
utilities
classWithTraits

^ classWithTraits ifNil: [
classWithTraits := self class classInstaller make: [ :aBuilder |
aBuilder
name: #SomeObject;
superclass: Object;
traitComposition: self trait1 + self trait2;
package: #'MonticelloTonel-Tests' ].
classesAndTraits add: classWithTraits.
classWithTraits ]
^ TonelTestResource current classWithTraits
Original file line number Diff line number Diff line change
@@ -1,13 +1,4 @@
utils
utilities
classWithTraitsWithClassComposition

^ classWithTraitsWithClassComposition ifNil: [
classWithTraitsWithClassComposition := self class classInstaller make: [ :aBuilder |
aBuilder
name: #SomeObject2;
superclass: Object;
traitComposition: self trait1 + self trait2;
classTraitComposition: self trait1 classTrait + self trait2 classTrait - #m1;
package: #'MonticelloTonel-Tests' ].
classesAndTraits add: classWithTraitsWithClassComposition.
classWithTraitsWithClassComposition ]
^ TonelTestResource current classWithTraitsWithClassComposition
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
utils
utilities
trait1

^ trait1 ifNil: [
trait1 := Trait named: #T1 uses: #() package: #'MonticelloTonel-Tests'.
classesAndTraits add: trait1.
trait1 ]
^ TonelTestResource current trait1
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
utils
utilities
trait2

^ trait2 ifNil: [
trait2 := Trait named: #T2 uses: #() package: #'MonticelloTonel-Tests'.
classesAndTraits add: trait2.
trait2 ]
^ TonelTestResource current trait2
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,7 @@
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"instvars" : [
"classesAndTraits",
"classWithTraits",
"trait1",
"trait2",
"classWithTraitsWithClassComposition"
],
"instvars" : [ ],
"name" : "AbstractTonelTest",
"type" : "normal"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
I am a test resource holding some classes for Tonel to use for the reading and writing tests.
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
accessing
classWithTraits

^ classWithTraits ifNil: [
classWithTraits := self class classInstaller make: [ :aBuilder |
aBuilder
name: #SomeObject;
superclass: Object;
traitComposition: self trait1 + self trait2;
package: #'MonticelloTonel-Tests' ].
classesAndTraits add: classWithTraits.
classWithTraits ]
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
accessing
classWithTraitsWithClassComposition

^ classWithTraitsWithClassComposition ifNil: [
classWithTraitsWithClassComposition := self class classInstaller make: [ :aBuilder |
aBuilder
name: #SomeObject2;
superclass: Object;
traitComposition: self trait1 + self trait2;
classTraitComposition: self trait1 classTrait + self trait2 classTrait - #m1;
package: #'MonticelloTonel-Tests' ].
classesAndTraits add: classWithTraitsWithClassComposition.
classWithTraitsWithClassComposition ]
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
accessing
trait1

^ trait1 ifNil: [
trait1 := Trait named: #T1 uses: #( ) package: #'MonticelloTonel-Tests'.
classesAndTraits add: trait1.
trait1 ]
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
accessing
trait2

^ trait2 ifNil: [
trait2 := Trait named: #T2 uses: #( ) package: #'MonticelloTonel-Tests'.
classesAndTraits add: trait2.
trait2 ]
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"commentStamp" : "CyrilFerlicot 9/26/2023 12:01",
"super" : "TestResource",
"category" : "MonticelloTonel-Tests-Base",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"instvars" : [
"classesAndTraits",
"classWithTraits",
"trait1",
"trait2",
"classWithTraitsWithClassComposition"
],
"name" : "TonelTestResource",
"type" : "normal"
}