Skip to content

Commit

Permalink
test: Add native API tests
Browse files Browse the repository at this point in the history
  • Loading branch information
fabriziodemaria committed May 20, 2024
1 parent 204801c commit 85e37e4
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions src/test/java/com/spotify/confidence/ConfidenceTest.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
package com.spotify.confidence;

import static org.junit.jupiter.api.Assertions.*;

import org.junit.jupiter.api.Test;

public class ConfidenceTest {
private final FakeEventSenderEngine fakeEngine = new FakeEventSenderEngine(new FakeClock());
private final ResolverClientTestUtils.FakeFlagResolverClient fakeFlagResolverClient =
new ResolverClientTestUtils.FakeFlagResolverClient();

@Test
void getValue() {
final Confidence confidence = Confidence.create(fakeEngine, fakeFlagResolverClient);
Integer value = confidence.getValue("flag.prop-E", 20);
assertEquals(50, value);
}
}

0 comments on commit 85e37e4

Please sign in to comment.