Skip to content

Commit

Permalink
test: ✅ adjust test values for getElementAxes
Browse files Browse the repository at this point in the history
  • Loading branch information
DerZade authored Sep 5, 2023
1 parent 27d8937 commit af69db9
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions test/getElementAxes.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,14 @@ describe('getElementAxes', () => {
it('should return the correct axes on LTR pages', async () => {
const page = getPage();

// see https://drafts.csswg.org/css-writing-modes/#logical-to-physical
const CASES = [
{ id: 'my-elem-h-tb', block: 'top-bottom', inline: 'left-right' },
{ id: 'my-elem-v-rl', block: 'right-left', inline: 'top-bottom' },
{ id: 'my-elem-v-lr', block: 'left-right', inline: 'top-bottom' }
// TODO: uncomment once chrome supports writing-mode sideways-rl / sideways-lr
// { id: 'my-elem-s-rl', block: 'right-left', inline: 'top-bottom' },
// { id: 'my-elem-s-lr', block: 'left-right', inline: 'top-bottom' }
// { id: 'my-elem-s-lr', block: 'left-right', inline: 'bottom-top' }
];

const promises = CASES.map(({ id, ...expected }) =>
Expand Down Expand Up @@ -41,13 +42,14 @@ describe('getElementAxes', () => {
document.dir = 'rtl';
});

// see https://drafts.csswg.org/css-writing-modes/#logical-to-physical
const CASES = [
{ id: 'my-elem-h-tb', block: 'top-bottom', inline: 'right-left' },
{ id: 'my-elem-v-rl', block: 'right-left', inline: 'bottom-top' },
{ id: 'my-elem-v-lr', block: 'left-right', inline: 'bottom-top' }
// TODO: uncomment once chrome supports writing-mode sideways-rl / sideways-lr
// { id: 'my-elem-s-rl', block: 'right-left', inline: 'bottom-top' },
// { id: 'my-elem-s-lr', block: 'left-right', inline: 'bottom-top' }
// { id: 'my-elem-s-lr', block: 'left-right', inline: 'top-bottom' }
];

const promises = CASES.map(({ id, ...expected }) =>
Expand Down

0 comments on commit af69db9

Please sign in to comment.