def test_unfinished_point(): _test_asc_exception( '''("CellBody" (Color Red) (CellBody) (1 1''', RawDataError, 'Error converting: "" to float', ':4:error')
def test_unknown_token(): _test_asc_exception( ''' ("CellBody" (Color Red) (CellBody) (1 1 0 1 S1) (Z 1 0 1 S2) ; <-- Z is a BAD token (-1 -1 0 2 S3) )''', RawDataError, "Unexpected token: Z", ":6:error")
def test_unfinished_file(): _test_asc_exception( ''' ((Dendrite) (3 -4 0 2) (3 -6 0 2) (3 -8 0 2) (3 -10 0 2) ( (3 -10 0 2) (0 -10 0 2) (-3 -10 0 2) | ''', RawDataError, "Hit end of file while consuming a neurite", ":12:error")
def test_multiple_soma(): _test_asc_exception( ''' ("CellBody" (Color Red) (CellBody) (1 1 0 1 S1) (-1 1 0 1 S2) ) ("CellBody" (Color Red) (CellBody) (1 1 0 1 S1) (-1 1 0 1 S2) )''', SomaError, 'A soma is already defined', ':14:error')