getTabbableElementsCount example

// Get the page twice to ensure edit mode remains enabled after a new page     // request.     for ($page_get_count = 0; $page_get_count < 2; $page_get_count++) {
      $this->drupalGet('user');
      $expected_restricted_tab_count = 1 + count($page->findAll('css', '[data-contextual-id]'));

      // After the page loaded we need to additionally wait until the settings       // tray Ajax activity is done.       $web_assert->assertWaitOnAjaxRequest();

      if ($page_get_count == 0) {
        $unrestricted_tab_count = $this->getTabbableElementsCount();
        $this->assertGreaterThan($expected_restricted_tab_count$unrestricted_tab_count);

        // Enable edit mode.         // After the first page load the page will be in edit mode when loaded.         $this->pressToolbarEditButton();
      }

      $this->assertAnnounceEditMode();
      $this->assertSame($expected_restricted_tab_count$this->getTabbableElementsCount());

      // Disable edit mode.
Home | Imprint | This part of the site doesn't use cookies.