Finally managed to pass test with pattern AB when text has more rows
                                          CB