Test class for
Singleton4
- Construct two
Singleton4
instances/objects using the
Singleton4.getInstance()
method
- Set the
Singleton4.data
value of the first instance and print information
concerning both objects to the screen
- Check - on the screen output - that the references and values for both
objects are the same
EXPECTED (TYPICAL) OUTPUT
First singleton4: models.Singleton1@70dea4e
First singleton4 data value = 34
Second singleton4: models.Singleton1@70dea4e
Second singleton4 data value = 34
CHECK - on the previous output - that the references and values for both objects are the same