def test_zero_width_character(assert_pixels):
    # Test regression: https://github.com/Kozea/WeasyPrint/issues/1508
    assert_pixels('''
        ______
        _RRRR_
        _RRRR_
        ______
    ''', '''
      <style>
        @page {
          size: 6px 4px;
          margin: 1px;
        }
        body {
          color: red;
          font-family: weasyprint;
          font-size: 2px;
          line-height: 1;
        }
      </style>
      <div>a&zwnj;b</div>''')
,
tests/draw/test_text.py