Skip to content

Commit

Permalink
addressing review
Browse files Browse the repository at this point in the history
Signed-off-by: Giovanni Liva <this_that@hotmail.it>
  • Loading branch information
thisthat committed Aug 3, 2023
1 parent 6be8c10 commit 539700e
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 30 deletions.
20 changes: 0 additions & 20 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -47,14 +47,6 @@
<junit.jupiter.version>5.10.0</junit.jupiter.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<<<<<<< HEAD
<<<<<<< HEAD

=======
<testcontainers.version>1.18.3</testcontainers.version>
>>>>>>> 473240e (add smoke test)
=======
>>>>>>> cbcfba4 (remove smoketests in favor of e2e tests)
</properties>

<dependencies>
Expand Down Expand Up @@ -183,18 +175,6 @@
<version>7.13.0</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.testcontainers</groupId>
<artifactId>testcontainers</artifactId>
<version>${testcontainers.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.testcontainers</groupId>
<artifactId>junit-jupiter</artifactId>
<version>${testcontainers.version}</version>
<scope>test</scope>
</dependency>
<!-- end test -->
</dependencies>

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
package dev.openfeature.contrib.providers.flagd.grpc;

/**
* A converter lambda.
*/
@FunctionalInterface
public interface Convert<OutT extends Object, InT extends Object> {
OutT convert(InT value);
}
Original file line number Diff line number Diff line change
Expand Up @@ -231,12 +231,4 @@ private static <T> T getField(Message message, String name) {
private static Descriptors.FieldDescriptor getFieldDescriptor(Message message, String name) {
return message.getDescriptorForType().findFieldByName(name);
}

/**
* A converter lambda.
*/
@FunctionalInterface
public interface Convert<OutT extends Object, InT extends Object> {
OutT convert(InT value);
}
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package dev.openfeature.contrib.providers.flagd.e2e;

import dev.openfeature.contrib.providers.flagd.FlagdOptions;
import dev.openfeature.contrib.providers.flagd.FlagdProvider;
import dev.openfeature.sdk.Client;
import dev.openfeature.sdk.EvaluationContext;
Expand Down Expand Up @@ -50,9 +51,10 @@ public class StepDefinitions {
@BeforeAll()
@Given("a provider is registered with cache disabled")
public static void setup() {
// set a generous deadline, to prevent timeouts in actions
FlagdOptions conf = FlagdOptions.builder().deadline(3000).build();
// TODO: when the FlagdProvider is updated to support caching, we might need to disable it here for this test to work as expected.
FlagdProvider provider = new FlagdProvider();
provider.setDeadline(3000); // set a generous deadline, to prevent timeouts in actions
FlagdProvider provider = new FlagdProvider(conf);
OpenFeatureAPI.getInstance().setProvider(provider);
client = OpenFeatureAPI.getInstance().getClient();
}
Expand Down

0 comments on commit 539700e

Please sign in to comment.