Singletons testing code