def test_footnote_column_p_before(assert_pixels):
    assert_pixels('''
        KKKK_____
        KKKK_____
        RRRR_RRRR
        RRRR_RRRR
        RRRR_RR__
        RRRR_RR__
        _________
        RRRRRRRR_
        RRRRRRRR_
        RRRRRRRR_
        RRRRRRRR_
        RRRRRRRR_
        RRRRRRRR_
        RRRR_RR__
        RRRR_RR__
        _________
        _________
        _________
        _________
        _________
        _________
        _________
        _________
        _________
        _________
        _________
    ''', '''
    <style>
      @page {
        size: 9px 13px;
      }
      body {
        font-family: weasyprint;
        font-size: 2px;
        line-height: 1;
      }
      div {
        color: red;
        columns: 2;
        column-gap: 1px;
      }
      span {
        float: footnote;
      }
    </style>
    <p>ab</p>
    <div>
    a<span>de</span> a<span>de</span>
    a<span>de</span> a ab a </div>''')
,
tests/draw/test_footnote_column.py