コード例 #1
0
 def test_get_pool_size_with_custom_size_small(self, _):
     """
     Calling get_pool_size with fastsync_parallelism smaller than cpu core count return the fastsync_parallelism
     """
     assert utils.get_pool_size({'fastsync_parallelism': 2}) == 2
コード例 #2
0
 def test_get_pool_size_with_custom_size_big(self, _):
     """
     Calling get_pool_size with fastsync_parallelism greater than cpu core count return the cpu core count
     """
     assert utils.get_pool_size({'fastsync_parallelism': 20}) == 10
コード例 #3
0
 def test_get_pool_size_without_custom_size(self, _):
     """
     Calling get_pool_size without providing fastsync_parallelism return cpu core count
     """
     assert utils.get_pool_size({}) == 10