Beispiel #1
0
 def test_singleton(self):
     """
         Testing whether Loader is truly a singleton
     """
     # Create a 'new' Loader
     b = Loader()
     self.assertEqual(self.loader._get_registry_creation_time(),
                      b._get_registry_creation_time())
Beispiel #2
0
class designtest(unittest.TestCase):
    
    def setUp(self):
        self.loader = Loader()
        
    def test_singleton(self):
        """
            Testing whether Loader is truly a singleton
        """
        # Create a 'new' Loader
        b = Loader()
        self.assertEqual(self.loader._get_registry_creation_time(),
                         b._get_registry_creation_time())