Skip to content

"Table Footer Should Contain" should take into account <th> elements #1436

Closed

Description

@php-coder

Table Footer Should Contain is always looking for <td> tag within <tfoot>:

def _find_by_footer(self, table_locator, content):
return self._find(table_locator, '//tfoot//td', content)

but it's valid to have <th> tags there also. Example: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/tfoot

Can we have this keyword fixed to take into account <th> tags as well?

Activity

  1. aaltat commented on Aug 29, 2019

    @aaltat
    Contributor

    As with #1437 would it possible to get static HTML page and simple test case that demonstrates the problem?

  2. aaltat commented on Sep 18, 2019

    @aaltat
    Contributor

    I do not have time investigate this in the near future. Therefore I am closing this issue. If you @php-coder want to return in the issue, please reopen the issue.

  3. php-coder commented on Mar 25, 2026

    @php-coder
    Author

    After 7 years I came back in order to report this issue and I found my own report! It's still valid.

    @aaltat Could you, please, reopen the issue?

  4. aaltat commented on Mar 25, 2026

    @aaltat
    Contributor

    I am not anymore maintaining this library, so I leave the decision on the current maintainers.

  5. emanlove commented on Mar 25, 2026

    @emanlove
    Member

    I have reopened it. As with any ticket, work gets prioritized. Having an issue that is very old but not widely asked about, even is it is still an issue, usually gets less focus. Something that helps here greatly to move something like this along is a PR provided by the community to resolve it.

  6. b-vamsipunnam commented on Nov 8, 2026

    @b-vamsipunnam
    Contributor

    Hi @emanlove ,

    I picked this up and opened PR #2000. It updates Table Footer Should Contain to find text in both <th> and <td> cells inside <tfoot>. I added a regression test for the reported case, and all 40 table acceptance tests passed locally.

    #2000

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions