Skip to content

Commit

Permalink
fix: Checkstyle
Browse files Browse the repository at this point in the history
  • Loading branch information
fabriziodemaria committed May 21, 2024
1 parent b2265a5 commit 9f444b9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 15 deletions.
10 changes: 6 additions & 4 deletions src/test/java/com/spotify/confidence/ConfidenceTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -76,20 +76,21 @@ void getFullValue() {
@Test
void getValueIncompatibleType() {
final Confidence confidence = Confidence.create(fakeEngine, fakeFlagResolverClient);
FlagEvaluation<String> evaluation = confidence.getEvaluation("flag.prop-E", "test");
final FlagEvaluation<String> evaluation = confidence.getEvaluation("flag.prop-E", "test");
assertEquals("test", evaluation.getValue());
assertEquals("", evaluation.getVariant());
assertEquals("ERROR", evaluation.getReason());
assertEquals(ErrorType.INVALID_VALUE_TYPE, evaluation.getErrorType().get());
assertEquals(
"Default type class java.lang.String, but value of type class com.spotify.confidence.ConfidenceValue$Integer",
"Default type class java.lang.String, but value of "
+ "type class com.spotify.confidence.ConfidenceValue$Integer",
evaluation.getErrorMessage().get());
}

@Test
void getValueUnsupportedType() {
final Confidence confidence = Confidence.create(fakeEngine, fakeFlagResolverClient);
FlagEvaluation<Date> evaluation =
final FlagEvaluation<Date> evaluation =
confidence.getEvaluation("flag.prop-E", Date.valueOf("2024-4-2"));
assertEquals(Date.valueOf("2024-4-2"), evaluation.getValue());
assertEquals("", evaluation.getVariant());
Expand All @@ -101,7 +102,8 @@ void getValueUnsupportedType() {
@Test
void getNullValue() {
final Confidence confidence = Confidence.create(fakeEngine, fakeFlagResolverClient);
FlagEvaluation<String> evaluation = confidence.getEvaluation("flag.prop-G.prop-H", "test");
final FlagEvaluation<String> evaluation =
confidence.getEvaluation("flag.prop-G.prop-H", "test");
assertEquals("test", evaluation.getValue());
assertEquals("flags/flag/variants/var-A", evaluation.getVariant());
assertEquals("RESOLVE_REASON_MATCH", evaluation.getReason());
Expand Down
11 changes: 0 additions & 11 deletions src/test/java/com/spotify/confidence/ConfidenceTypeMapperTest.java

This file was deleted.

0 comments on commit 9f444b9

Please sign in to comment.