$this->formBuilder()->buildForm('\Drupal\block_test\Form\TestForm', $form_state), 'form2' => $this->formBuilder()->buildForm('\Drupal\block_test\Form\FavoriteAnimalTestForm', $form_state), ]; // Output all attached placeholders trough drupal_set_message(), so we can // see if there's only one in the tests. $post_render_callable = function ($elements) { $matches = []; preg_match_all('