-
Notifications
You must be signed in to change notification settings - Fork 2
ActiveAnimalsManager Test
Vansh Mittal edited this page Sep 12, 2024
·
2 revisions
-
ActiveAnimalsManager
: The singleton class being tested, which manages a set of active animals in the game. -
GameTime
: A service that mimics and controls the time of the game. -
EventListener0
: To ensure that the right events are triggered, a mocked event listener is used. -
ServiceLocator
: Registers services used in the game to isolate the class being tested. -
GameExtension
,MockitoExtension
: These are JUnit extensions that allow for game-specific configuration and Mockito functionality.
-
setUp()
: To guarantee test independence, the active animals set is cleaned and the singleton instance ofActiveAnimalsManager
is fetched prior to each test. -
testSingletonInstance()
: This test ensures that ActiveAnimalsManager follows the singleton design pattern by asserting that two calls to getInstance() return the same instance. -
testAddAnimal(
): The test verifies that an animal (such as "Monkey") introduced to the manager shows up in the collection of active animals. -
testRemoveAnimal()
: It confirms the ability to correctly remove an animal (like "Gorilla") introduced to the active animals set. -
testGetActiveAnimals()
: The test makes sure that only the animals that have been added are returned as the correct set of active animals by thegetActiveAnimals()
method.
Inventory System
Scoring System
Food Recipes
Level System
Player Actions
Ordering System
Stations
Items
Map Design
Customers
Pause Menu
Upgrades
End of Day Display
Day Night Cycle
Moral System
Debug Terminal
Game Interactions Tutorial
Backstory Cutscenes
Entities and Components
Input Handling
Game Screens and Areas
Fire Extinguisher Handler Component
MainGameActions Create Docket Triggers
Main Game Order Button Display
BackstoryCutsceneDisplay Test Plan
Test Plan for MainGameOrderTicketDisplay
Test Plan for MainGameOrderBtnDisplay
Test Plan for DocketLineDisplay
Test plan for RandomComboService
Test plan for SpeedBoostUpgrade
Test plan for DancePartyUpgrade