+
+ // Test that the keyboard focus is on the dropdown button of the View we
+ // just disabled.
+ $this->assertTrue($this->getSession()->evaluateScript("jQuery(document.activeElement).parent().is('li.enable.dropbutton-action')"));
+ $this->assertEquals($view_description, $this->getSession()->evaluateScript("jQuery(document.activeElement).parents('tr').find('h3').text()"));
+
+ // Enable the view again and ensure we have the focus on the edit button.
+ $this->getSession()->evaluateScript('jQuery(document.activeElement).click()');
+ $session->assertWaitOnAjaxRequest();
+
+ $this->assertTrue($this->getSession()->evaluateScript("jQuery(document.activeElement).parent().is('li.edit.dropbutton-action')"));
+ $this->assertEquals($view_description, $this->getSession()->evaluateScript("jQuery(document.activeElement).parents('tr').find('h3').text()"));