SpeechSynthesisTest: check the number of voices against the length of the test data array (VoiceData.voices) instead of hard coding it.

This commit is contained in:
Reece H. Dunn
2012-12-17 14:10:18 +00:00
parent b5db940457
commit 87ccc3a61e
@@ -108,7 +108,7 @@ public class SpeechSynthesisTest extends AndroidTestCase
final SpeechSynthesis synth = new SpeechSynthesis(getContext(), mCallback);
mVoices = synth.getAvailableVoices();
assertThat(mVoices, is(notNullValue()));
assertThat(mVoices.size(), is(78));
assertThat(mVoices.size(), is(VoiceData.voices.length));
}
return mVoices;
}