# Enable IME
SEND_KEY	ON
RESET_CONTEXT

# Prediction w/o experimental features.
SEND_KEYS	a
SEND_KEY	TAB
EXPECT_PREEDIT	あ
SEND_KEY	ENTER

EXPECT_USAGE_STATS_COUNT	ConsumedSendKey	4
EXPECT_USAGE_STATS_COUNT	UnconsumedSendKey	0
EXPECT_USAGE_STATS_COUNT	Commit	1
EXPECT_USAGE_STATS_COUNT	CommitFromConversion	0
EXPECT_USAGE_STATS_COUNT	CommitFromPrediction	1
EXPECT_USAGE_STATS_COUNT	CommitFromComposition	0
EXPECT_USAGE_STATS_COUNT	CommitFromUnknown	0

EXPECT_USAGE_STATS_COUNT	CommitFromConversionInChromeOmnibox	0
EXPECT_USAGE_STATS_COUNT	CommitFromPredictionInChromeOmnibox	0
EXPECT_USAGE_STATS_COUNT	CommitFromCompositionInChromeOmnibox	0
EXPECT_USAGE_STATS_COUNT	CommitFromConversionInGoogleSearchBox	0
EXPECT_USAGE_STATS_COUNT	CommitFromPredictionInGoogleSearchBox	0
EXPECT_USAGE_STATS_COUNT	CommitFromCompositionInGoogleSearchBox	0

EXPECT_USAGE_STATS_COUNT	ConversionCandidates0	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates1	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates2	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates3	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates4	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates5	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidatesGE10	0

EXPECT_USAGE_STATS_COUNT	TransliterationCandidates0	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates1	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates2	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates3	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates4	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates5	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidatesGE10	0

EXPECT_USAGE_STATS_COUNT	PredictionCandidates0	1
EXPECT_USAGE_STATS_COUNT	PredictionCandidates1	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidates2	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidates3	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidates4	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidates5	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidatesGE10	0

EXPECT_USAGE_STATS_COUNT	MouseSelect	0
EXPECT_USAGE_STATS_COUNT	BackSpaceAfterCommit	0

EXPECT_USAGE_STATS_TIMING	SubmittedSegmentLengthx1000	1000	1	1000	1000
EXPECT_USAGE_STATS_TIMING	SubmittedSegmentNumberx1000	1000	1	1000	1000
EXPECT_USAGE_STATS_TIMING	SubmittedLengthx1000	1000	1	1000	1000
EXPECT_USAGE_STATS_COUNT	SubmittedTotalLength	1

# Prediction w/ chrome_omnibox
EXPECT_PREEDIT	
SEND_KEYS	a
SEND_KEY	TAB
EXPECT_PREEDIT	あ
SEND_KEY_WITH_OPTION	ENTER	context.experimental_features="chrome_omnibox"

EXPECT_USAGE_STATS_COUNT	ConsumedSendKey	7
EXPECT_USAGE_STATS_COUNT	UnconsumedSendKey	0
EXPECT_USAGE_STATS_COUNT	Commit	2
EXPECT_USAGE_STATS_COUNT	CommitFromConversion	0
EXPECT_USAGE_STATS_COUNT	CommitFromPrediction	2
EXPECT_USAGE_STATS_COUNT	CommitFromComposition	0
EXPECT_USAGE_STATS_COUNT	CommitFromUnknown	0

EXPECT_USAGE_STATS_COUNT	CommitFromConversionInChromeOmnibox	0
EXPECT_USAGE_STATS_COUNT	CommitFromPredictionInChromeOmnibox	1
EXPECT_USAGE_STATS_COUNT	CommitFromCompositionInChromeOmnibox	0
EXPECT_USAGE_STATS_COUNT	CommitFromConversionInGoogleSearchBox	0
EXPECT_USAGE_STATS_COUNT	CommitFromPredictionInGoogleSearchBox	0
EXPECT_USAGE_STATS_COUNT	CommitFromCompositionInGoogleSearchBox	0

EXPECT_USAGE_STATS_COUNT	ConversionCandidates0	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates1	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates2	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates3	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates4	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates5	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidatesGE10	0

EXPECT_USAGE_STATS_COUNT	TransliterationCandidates0	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates1	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates2	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates3	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates4	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates5	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidatesGE10	0

EXPECT_USAGE_STATS_COUNT	PredictionCandidates0	2
EXPECT_USAGE_STATS_COUNT	PredictionCandidates1	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidates2	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidates3	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidates4	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidates5	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidatesGE10	0

EXPECT_USAGE_STATS_COUNT	MouseSelect	0
EXPECT_USAGE_STATS_COUNT	BackSpaceAfterCommit	0

EXPECT_USAGE_STATS_TIMING	SubmittedSegmentLengthx1000	2000	2	1000	1000
EXPECT_USAGE_STATS_TIMING	SubmittedSegmentNumberx1000	2000	2	1000	1000
EXPECT_USAGE_STATS_TIMING	SubmittedLengthx1000	2000	2	1000	1000
EXPECT_USAGE_STATS_COUNT	SubmittedTotalLength	2

# Prediction w/ google_search_box
SEND_KEYS	a
SEND_KEY	TAB
SEND_KEY_WITH_OPTION	ENTER	context.experimental_features="google_search_box"

EXPECT_USAGE_STATS_COUNT	ConsumedSendKey	10
EXPECT_USAGE_STATS_COUNT	UnconsumedSendKey	0
EXPECT_USAGE_STATS_COUNT	Commit	3
EXPECT_USAGE_STATS_COUNT	CommitFromConversion	0
EXPECT_USAGE_STATS_COUNT	CommitFromPrediction	3
EXPECT_USAGE_STATS_COUNT	CommitFromComposition	0
EXPECT_USAGE_STATS_COUNT	CommitFromUnknown	0

EXPECT_USAGE_STATS_COUNT	CommitFromConversionInChromeOmnibox	0
EXPECT_USAGE_STATS_COUNT	CommitFromPredictionInChromeOmnibox	1
EXPECT_USAGE_STATS_COUNT	CommitFromCompositionInChromeOmnibox	0
EXPECT_USAGE_STATS_COUNT	CommitFromConversionInGoogleSearchBox	0
EXPECT_USAGE_STATS_COUNT	CommitFromPredictionInGoogleSearchBox	1
EXPECT_USAGE_STATS_COUNT	CommitFromCompositionInGoogleSearchBox	0

EXPECT_USAGE_STATS_COUNT	ConversionCandidates0	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates1	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates2	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates3	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates4	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidates5	0
EXPECT_USAGE_STATS_COUNT	ConversionCandidatesGE10	0

EXPECT_USAGE_STATS_COUNT	TransliterationCandidates0	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates1	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates2	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates3	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates4	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidates5	0
EXPECT_USAGE_STATS_COUNT	TransliterationCandidatesGE10	0

EXPECT_USAGE_STATS_COUNT	PredictionCandidates0	3
EXPECT_USAGE_STATS_COUNT	PredictionCandidates1	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidates2	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidates3	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidates4	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidates5	0
EXPECT_USAGE_STATS_COUNT	PredictionCandidatesGE10	0

EXPECT_USAGE_STATS_COUNT	MouseSelect	0
EXPECT_USAGE_STATS_COUNT	BackSpaceAfterCommit	0

EXPECT_USAGE_STATS_TIMING	SubmittedSegmentLengthx1000	3000	3	1000	1000
EXPECT_USAGE_STATS_TIMING	SubmittedSegmentNumberx1000	3000	3	1000	1000
EXPECT_USAGE_STATS_TIMING	SubmittedLengthx1000	3000	3	1000	1000
EXPECT_USAGE_STATS_COUNT	SubmittedTotalLength	3
