The gherkin tests are flaky because we need to wait for a state change using a timeout:
Awaitility.await().atMost(Duration.ofSeconds(30)).until(() -> {
ProviderState providerState1 = client.getProviderState();
return providerState1 == providerState;
});
We could add an listener on OpenFeatureClient and FeatureProviderStateManager and notify this listener when the state changes.
Than we could use await, anotify insted of using timeouts.
What do you think?