def test_leader_float_small(assert_pixels):
    assert_pixels('''
        bbRRBB__BB____BB
        bbRRBB__BB____BB
        RR__BB__BB____BB
        RR__BB__BB____BB
    ''', '''
      <style>
        @page {
          size: 16px 4px;
        }
        body {
          color: red;
          font-family: weasyprint;
          font-size: 2px;
          line-height: 1;
        }
        article {
          background: lime;
          color: navy;
          float: left;
        }
        div::after {
          color: blue;
          content: leader('. ') 'a';
        }
      </style>
      <div>a<article>a</article></div>
      <div>a</div>
    ''')
,
tests/draw/test_leader.py