Test passes if the joining forms look correct.

WITH DIR=RTL

Ordinary text with just spaces between

ع ع‍ ‍ع‍ ‍ع

Ordinary text with LRM between

ع ‎ ع‍ ‎ ‍ع‍ ‎ ‍ع

Spans

ع ع‍ ‍ع‍ ‍ع

bdi

ع ع‍ ‍ع‍ ‍ع

Table cells

‍ع‍ع‍ع‍ع

Flex box

‍ع‍ع‍ع‍ع

WITHOUT DIR=RTL

Ordinary text with just spaces between

ع ع‍ ‍ع‍ ‍ع

Ordinary text with LRM between

ع ‎ ع‍ ‎ ‍ع‍ ‎ ‍ع

Spans

ع ع‍ ‍ع‍ ‍ع

bdi

ع ع‍ ‍ع‍ ‍ع

Table cells

‍ع‍ع‍ع‍ع

Flex box

‍ع‍ع‍ع‍ع