'Regression test for https://aeon.stsci.edu/ssb/trac/pyfits/ticket/193
Ensure that the __repr__() for cards represented with CONTINUE cards is
split across multiple lines (broken at each *physical* card).'

def test_long_string_repr(self):

    header = fits.Header()
    header['TEST1'] = ('Regular    value', 'Regular    comment')
    header['TEST2'] = (('long    string    value    ' * 10), ('long    comment    ' * 10))
    header['TEST3'] = ('Regular    value', 'Regular    comment')
    assert (repr(header).splitlines() == [str(fits.Card('TEST1', 'Regular    value', 'Regular    comment')), "TEST2            =    'long    string    value    long    string    value    long    string    value    long    string    &'    ", "CONTINUE        'value    long    string    value    long    string    value    long    string    value    long    &'        ", "CONTINUE        'string    value    long    string    value    long    string    value    &'                                                                        ", "CONTINUE        '&'    /    long    comment    long    comment    long    comment    long    comment    long                                ", "CONTINUE        '&'    /    comment    long    comment    long    comment    long    comment    long    comment                    ", "CONTINUE        ''    /    long    comment                                                                                                                                                                                                                    ", str(fits.Card('TEST3', 'Regular    value', 'Regular    comment'))])
