public function radioButtonsAreCheckedCorrectlyOnValidationErrors()
{
$this->browser->request('http://localhost/test/fluid/formobjects');
$form = $this->browser->getForm();
$form['post']['author']['emailAddress']->setValue('test_noValidEmail');
$form['post']['category']->setValue('bar');
$form['post']['subCategory']->setValue('bar');
$this->browser->submit($form);
$this->assertEquals('', $this->browser->getCrawler()->filterXPath('//input[@id="category_foo"]')->attr('checked'));
$this->assertEquals('checked', $this->browser->getCrawler()->filterXPath('//input[@id="category_bar"]')->attr('checked'));
$this->assertEquals('', $this->browser->getCrawler()->filterXPath('//input[@id="subCategory_foo"]')->attr('checked'));
$this->assertEquals('checked', $this->browser->getCrawler()->filterXPath('//input[@id="subCategory_bar"]')->attr('checked'));
$form['post']['category']->setValue('foo');
$form['post']['subCategory']->setValue('foo');
$this->browser->submit($form);
$this->assertEquals('checked', $this->browser->getCrawler()->filterXPath('//input[@id="category_foo"]')->attr('checked'));
$this->assertEquals('', $this->browser->getCrawler()->filterXPath('//input[@id="category_bar"]')->attr('checked'));
$this->assertEquals('checked', $this->browser->getCrawler()->filterXPath('//input[@id="subCategory_foo"]')->attr('checked'));
$this->assertEquals('', $this->browser->getCrawler()->filterXPath('//input[@id="subCategory_bar"]')->attr('checked'));
}