Improve test data creation #112
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "test-data-improvements"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Currently there is only one class used to add test data;
DataInitializer
. That class is already very large and causes a lot of merge conflicts when multiple changes are in the pipeline as noted by #109.This change makes it possible to have multiple classes adding test data so that each change adds its own class and thus there are no conflicts. It also has the benefit of making each class smaller and more self-contained for testing a specific feature.
Some additional infrastructure was added in the form of the
BaseData
andFactory
(naming improvements notwithstanding) interfaces to help each class add its own test data and re-use common data.Finally all test data related classes have been moved to their own module so they can be properly excluded when building for production but are included by default while developing.
Fixes #109
Future work
Many processes (and therefore service method implementations) rely on the time between certain events. For example a final seminar must be scheduled a set amount of days in advance. In the ideal world, the test data is populated using these service methods to more accurately represent an achievable real world state. Therefore there must be a way to manipulate time when adding test data.
Factory
interface as we discover more common steps that many populators must take.BaseData
interface as we discover more common data that many populators needCare must be taken that this data is final and useful in its base state since populators will rely on that state.
c17af42dc9
toe7d6698c11
WIP: Improve test data creationto Improve test data creation@ansv7779 Should we tag the branch as WIP ?