# This file contains a scenario for testing preedit text when a user uses
# 12-key toggle key layout on mobile.

# Enable IME
SEND_KEY	ON

SET_MOBILE_REQUEST
UPDATE_MOBILE_KEYBOARD	TWELVE_KEYS_TO_HIRAGANA	SPACE_OR_CONVERT_KEEPING_COMPOSITION
SWITCH_INPUT_MODE	HIRAGANA

# Simple toggling on symbols. First, in the forward order.
RESET_CONTEXT
SEND_KEYS	#
EXPECT_PREEDIT	、
SEND_KEYS	#
EXPECT_PREEDIT	。
SEND_KEYS	#
EXPECT_PREEDIT	？
SEND_KEYS	#
EXPECT_PREEDIT	！
SEND_KEYS	#
EXPECT_PREEDIT	・
SEND_KEYS	#
# Full-width space
EXPECT_PREEDIT	　
SEND_KEYS	#
EXPECT_PREEDIT	、

# Then reverse order.
UNDO_OR_REWIND
# Full-width space
EXPECT_PREEDIT	　
UNDO_OR_REWIND
EXPECT_PREEDIT	・
UNDO_OR_REWIND
EXPECT_PREEDIT	！
UNDO_OR_REWIND
EXPECT_PREEDIT	？
UNDO_OR_REWIND
EXPECT_PREEDIT	。
UNDO_OR_REWIND
EXPECT_PREEDIT	、


# Make sure tapping '#' toggles the last character, not adding a new character.
SEND_KEYS	#
EXPECT_PREEDIT	。

# Test with RIGHT key.
RESET_CONTEXT
SEND_KEYS	#
SEND_KEY	RIGHT
SEND_KEYS	#
EXPECT_PREEDIT	、、

RESET_CONTEXT
SEND_KEYS	##
SEND_KEY	RIGHT
SEND_KEYS	#
EXPECT_PREEDIT	。、

RESET_CONTEXT
SEND_KEYS	###
SEND_KEY	RIGHT
SEND_KEYS	#
EXPECT_PREEDIT	？、

RESET_CONTEXT
SEND_KEYS	####
SEND_KEY	RIGHT
SEND_KEYS	#
EXPECT_PREEDIT	！、

RESET_CONTEXT
SEND_KEYS	#####
SEND_KEY	RIGHT
SEND_KEYS	#
EXPECT_PREEDIT	・、

RESET_CONTEXT
SEND_KEYS	######
SEND_KEY	RIGHT
SEND_KEYS	#
# FULLWIDTH-WHITESPACE followed by IDEOGRAPHIC-COMMA.
EXPECT_PREEDIT	　、
