Exemplo n.º 1
0
 def test_remove(self, mock_flush, mock_remove_data, mock_datetime, mock_index):
     self.build_mock_index_and_datetime_now(mock_index, mock_datetime)
     cache = Cache('test', cache_max_age=1)
     cache.remove('valid_key_past')
     self.assertEquals(2, mock_flush.call_count)
     self.assertEquals(2, mock_remove_data.call_count)