Browse Source

VoiceData.Exception: use AssertionError instead of Exception to get the language in the JUnit results.

master
Reece H. Dunn 12 years ago
parent
commit
32efff8500

+ 1
- 1
android/eSpeakTests/src/com/reecedunn/espeak/test/SpeechSynthesisTest.java View File

assertThat(voice.locale.getVariant(), is(data.variant)); assertThat(voice.locale.getVariant(), is(data.variant));
assertThat(voice.toString(), is(data.name)); assertThat(voice.toString(), is(data.name));
} }
catch (Exception e)
catch (AssertionError e)
{ {
throw new VoiceData.Exception(data, e); throw new VoiceData.Exception(data, e);
} }

+ 1
- 1
android/eSpeakTests/src/com/reecedunn/espeak/test/TextToSpeechTest.java View File

assertThat(mEngine.getLanguage().getCountry(), is("")); assertThat(mEngine.getLanguage().getCountry(), is(""));
assertThat(mEngine.getLanguage().getVariant(), is("")); assertThat(mEngine.getLanguage().getVariant(), is(""));
} }
catch (Exception e)
catch (AssertionError e)
{ {
throw new VoiceData.Exception(data, e); throw new VoiceData.Exception(data, e);
} }

+ 1
- 1
android/eSpeakTests/src/com/reecedunn/espeak/test/VoiceData.java View File

{ {
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;


public Exception(Voice voice, java.lang.Exception context)
public Exception(Voice voice, AssertionError context)
{ {
super("Voice \"" + voice.name + "\" -- " + context); super("Voice \"" + voice.name + "\" -- " + context);
} }

Loading…
Cancel
Save