Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add layout-table-matches method #2400

Merged
merged 3 commits into from
Jul 20, 2020
Merged

Conversation

WilcoFiers
Copy link
Contributor

@WilcoFiers WilcoFiers commented Jul 20, 2020

TECH DEBT: There are no tests for this. Because this matches isn't used in any rule, it can't be accessed on the axe object. This can be solved once we have Babel enabled on our tests.

Closes issue:

Reviewer checks

Required fields, to be filled out by PR reviewer(s)

  • Follows the commit message policy, appropriate for next version
  • Code is reviewed for security

@WilcoFiers WilcoFiers requested a review from a team as a code owner July 20, 2020 13:05
Copy link
Contributor

@straker straker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You'll need to export this function in the metadata-function-map file so it a rule can use it by name. https://github.com/dequelabs/axe-core/blob/develop/lib/core/base/metadata-function-map.js

import { isDataTable } from '../commons/table';
import { isFocusable } from '../commons/dom';

// TODO: es-modules add tests. No way to access this on the `axe` object
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like an "ES Module" to me. I do not understand this TODO.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The issue is that we can't import this into our tests because those don't use es modules yet. Since I can't import it, and it isn't on the global axe object, there's no way for me to access this, so I haven't added tests for it.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see, thanks for clarifying.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I created a ticket for it so we don't forget #2403

@WilcoFiers WilcoFiers merged commit d7ba70f into develop Jul 20, 2020
@WilcoFiers WilcoFiers deleted the layout-table-matches branch July 20, 2020 15:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants