@mock.patch('concurrent.futures.ProcessPoolExecutor')
@mock.patch('compileall.compile_file')
def test_compile_one_worker(self, compile_file_mock, pool_mock):
    compileall.compile_dir(self.directory, quiet=True)
    self.assertFalse(pool_mock.called)
    self.assertTrue(compile_file_mock.called)
@mock.patch('concurrent.futures.ProcessPoolExecutor')
@mock.patch('compileall.compile_file')
def test_compile_one_worker(self, compile_file_mock, pool_mock):
    compileall.compile_dir(self.directory, quiet=True)
    self.assertFalse(pool_mock.called)
    self.assertTrue(compile_file_mock.called)