Bangladesh take lead as Test heads for a draw