mirror of
https://github.com/google/nomulus.git
synced 2025-05-15 17:07:15 +02:00
Rename "absent" to "empty" in test names
This is left over from the transition from Guava to Java 8 Optionals. ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=207154260
This commit is contained in:
parent
8664101687
commit
a111ff0b0a
3 changed files with 8 additions and 8 deletions
|
@ -69,12 +69,12 @@ public class RequestParametersTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testExtractOptionalParameter_notPresent_returnsAbsent() {
|
public void testExtractOptionalParameter_notPresent_returnsEmpty() {
|
||||||
assertThat(extractOptionalParameter(req, "spin")).isEmpty();
|
assertThat(extractOptionalParameter(req, "spin")).isEmpty();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testExtractOptionalParameter_empty_returnsAbsent() {
|
public void testExtractOptionalParameter_empty_returnsEmpty() {
|
||||||
when(req.getParameter("spin")).thenReturn("");
|
when(req.getParameter("spin")).thenReturn("");
|
||||||
assertThat(extractOptionalParameter(req, "spin")).isEmpty();
|
assertThat(extractOptionalParameter(req, "spin")).isEmpty();
|
||||||
}
|
}
|
||||||
|
@ -192,7 +192,7 @@ public class RequestParametersTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testOptionalExtractEnumValue_noValue_returnsAbsent() {
|
public void testOptionalExtractEnumValue_noValue_returnsEmpty() {
|
||||||
when(req.getParameter("spin")).thenReturn("");
|
when(req.getParameter("spin")).thenReturn("");
|
||||||
assertThat(extractOptionalEnumParameter(req, Club.class, "spin")).isEmpty();
|
assertThat(extractOptionalEnumParameter(req, Club.class, "spin")).isEmpty();
|
||||||
}
|
}
|
||||||
|
@ -239,7 +239,7 @@ public class RequestParametersTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testExtractOptionalDatetimeParameter_empty_returnsAbsent() {
|
public void testExtractOptionalDatetimeParameter_empty_returnsEmpty() {
|
||||||
when(req.getParameter("timeParam")).thenReturn("");
|
when(req.getParameter("timeParam")).thenReturn("");
|
||||||
assertThat(extractOptionalDatetimeParameter(req, "timeParam")).isEmpty();
|
assertThat(extractOptionalDatetimeParameter(req, "timeParam")).isEmpty();
|
||||||
}
|
}
|
||||||
|
|
|
@ -64,7 +64,7 @@ public final class RouterTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testRoute_pathMismatch_returnsAbsent() {
|
public void testRoute_pathMismatch_returnsEmpty() {
|
||||||
assertThat(Router.create(SlothComponent.class).route("/doge")).isEmpty();
|
assertThat(Router.create(SlothComponent.class).route("/doge")).isEmpty();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -92,7 +92,7 @@ public final class RouterTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testRoute_prefixDoesNotMatch_returnsAbsent() {
|
public void testRoute_prefixDoesNotMatch_returnsEmpty() {
|
||||||
assertThat(Router.create(PrefixComponent.class).route("")).isEmpty();
|
assertThat(Router.create(PrefixComponent.class).route("")).isEmpty();
|
||||||
assertThat(Router.create(PrefixComponent.class).route("/")).isEmpty();
|
assertThat(Router.create(PrefixComponent.class).route("/")).isEmpty();
|
||||||
assertThat(Router.create(PrefixComponent.class).route("/ulysses")).isEmpty();
|
assertThat(Router.create(PrefixComponent.class).route("/ulysses")).isEmpty();
|
||||||
|
|
|
@ -37,12 +37,12 @@ public class PhoneNumberParameterTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testConvert_empty_returnsAbsent() {
|
public void testConvert_empty_returnsEmpty() {
|
||||||
assertThat(instance.convert("")).isEmpty();
|
assertThat(instance.convert("")).isEmpty();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
public void testConvert_nullString_returnsAbsent() {
|
public void testConvert_nullString_returnsEmpty() {
|
||||||
assertThat(instance.convert("null")).isEmpty();
|
assertThat(instance.convert("null")).isEmpty();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue