def test_emacs_arguments():
 (result, cli) = _feed_cli_with_input(u'\x1b4x\n')
 assert (result.text == u'xxxx')
 (result, cli) = _feed_cli_with_input(u'\x1b44x\n')
 assert (result.text == (u'x' * 44))
 (result, cli) = _feed_cli_with_input(u'\x1b4\x1b4x\n')
 assert (result.text == (u'x' * 44))
 (result, cli) = _feed_cli_with_input(u'aaaa\x1b-\x1b[Cbbbb\n')
 assert (result.text == u'aaabbbba')
 (result, cli) = _feed_cli_with_input(u'aaaa\x1b-3\x1b[Cbbbb\n')
 assert (result.text == u'abbbbaaa')
 (result, cli) = _feed_cli_with_input(u'aaaa\x1b---3\x1b[Cbbbb\n')
 assert (result.text == u'abbbbaaa')

def test_emacs_arguments ( ) : ( result , cli ) = _feed_cli_with_input ( u'\x1b4x\n' ) assert ( result . text == u'xxxx' ) ( result , cli ) = _feed_cli_with_input ( u'\x1b44x\n' ) assert ( result . text == ( u'x' * 44 ) ) ( result , cli ) = _feed_cli_with_input ( u'\x1b4\x1b4x\n' ) assert ( result . text == ( u'x' * 44 ) ) ( result , cli ) = _feed_cli_with_input ( u'aaaa\x1b-\x1b[Cbbbb\n' ) assert ( result . text == u'aaabbbba' ) ( result , cli ) = _feed_cli_with_input ( u'aaaa\x1b-3\x1b[Cbbbb\n' ) assert ( result . text == u'abbbbaaa' ) ( result , cli ) = _feed_cli_with_input ( u'aaaa\x1b---3\x1b[Cbbbb\n' ) assert ( result . text == u'abbbbaaa' )
test various combinations of arguments in emacs mode .