mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-28 21:33:53 +01:00
Convert tests into Kotlin
This commit is contained in:
parent
e429667f3a
commit
e9b4ec62a1
4 changed files with 47 additions and 35 deletions
|
|
@ -1,32 +0,0 @@
|
|||
package fr.free.nrw.commons;
|
||||
|
||||
import org.junit.Assert;
|
||||
import org.junit.Test;
|
||||
|
||||
import static org.hamcrest.CoreMatchers.is;
|
||||
|
||||
public class UtilsTest {
|
||||
@Test public void stripLocalizedStringPass() {
|
||||
Assert.assertThat(Utils.stripLocalizedString("Hello"), is("Hello"));
|
||||
}
|
||||
|
||||
@Test public void stripLocalizedStringJa() {
|
||||
Assert.assertThat(Utils.stripLocalizedString("\"こんにちは\"@ja"), is("こんにちは"));
|
||||
}
|
||||
|
||||
@Test public void capitalizeLowercase() {
|
||||
Assert.assertThat(Utils.capitalize("hello"), is("Hello"));
|
||||
}
|
||||
|
||||
@Test public void capitalizeFullCaps() {
|
||||
Assert.assertThat(Utils.capitalize("HELLO"), is("HELLO"));
|
||||
}
|
||||
|
||||
@Test public void capitalizeNumbersPass() {
|
||||
Assert.assertThat(Utils.capitalize("12x"), is("12x"));
|
||||
}
|
||||
|
||||
@Test public void capitalizeJaPass() {
|
||||
Assert.assertThat(Utils.capitalize("こんにちは"), is("こんにちは"));
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue