File tree Expand file tree Collapse file tree 2 files changed +15
-0
lines changed
Expand file tree Collapse file tree 2 files changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -118,6 +118,20 @@ void testRemovingEntityFromEnvironment() {
118118 std::cout << " Success" << std::endl;
119119}
120120
121+ void testPlacingMultipleEntities () {
122+ std::cout << " ---" << std::endl;
123+ std::cout << " Test 10 - Placing multiple entities" << std::endl;
124+ Entity entity1 (" Bob" );
125+ Entity entity2 (" Phil" );
126+ Entity entity3 (" Clarisse" );
127+ Environment environment (" Earth" , 6 );
128+ environment.addEntity (entity1);
129+ environment.addEntity (entity2);
130+ environment.addEntity (entity3);
131+ assert (environment.getNumEntities () == 3 );
132+ std::cout << " Success" << std::endl;
133+ }
134+
121135void seedRandomNumberGenerator () {
122136 srand (time (NULL ));
123137}
@@ -136,5 +150,6 @@ int main() {
136150 testRemovingEntityFromGrid ();
137151 testPlacingEntityInEnvironment ();
138152 testRemovingEntityFromEnvironment ();
153+ testPlacingMultipleEntities ();
139154 return 0 ;
140155}
You can’t perform that action at this time.
0 commit comments