Skip to content

Commit 0c64c82

Browse files
committed
fix: for #1611 Only execute concurrent tests with VMLens
VMLens test run now takes 4s and there is no risk of hanging tests. The hanging tests was during executing ArchUnitTests with VMLens. Renamed VmLensTest to VmLensCT and added a filter in the VMlens plugin. increased timeout for gherkin tests to 30s from 10s Signed-off-by: ThomasKrieger <thomas.krieger@vmlens.com>
1 parent 857fb9d commit 0c64c82

File tree

3 files changed

+9
-5
lines changed

3 files changed

+9
-5
lines changed

pom.xml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@
196196
<dependency>
197197
<groupId>com.vmlens</groupId>
198198
<artifactId>api</artifactId>
199-
<version>1.2.13</version>
199+
<version>1.2.14</version>
200200
<scope>test</scope>
201201
</dependency>
202202

@@ -348,7 +348,7 @@
348348
</activation>
349349
<build>
350350
<plugins>
351-
<!--<plugin>
351+
<plugin>
352352
<groupId>com.vmlens</groupId>
353353
<artifactId>vmlens-maven-plugin</artifactId>
354354
<version>1.2.14</version>
@@ -359,11 +359,14 @@
359359
<goal>test</goal>
360360
</goals>
361361
<configuration>
362+
<includes>
363+
<include>**/*CT.java</include>
364+
</includes>
362365
<failIfNoTests>true</failIfNoTests>
363366
</configuration>
364367
</execution>
365368
</executions>
366-
</plugin>-->
369+
</plugin>
367370
<plugin>
368371
<artifactId>maven-dependency-plugin</artifactId>
369372
<version>3.8.1</version>

src/test/java/dev/openfeature/sdk/e2e/steps/ProviderSteps.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
import dev.openfeature.sdk.providers.memory.InMemoryProvider;
2626
import io.cucumber.java.en.Given;
2727
import io.cucumber.java.en.Then;
28+
import java.time.Duration;
2829
import java.util.Map;
2930
import org.awaitility.Awaitility;
3031

@@ -122,7 +123,7 @@ private void setupMockProvider(ErrorCode errorCode, String errorMessage, Provide
122123
break;
123124
default:
124125
}
125-
Awaitility.await().until(() -> {
126+
Awaitility.await().atMost(Duration.ofSeconds(30)).until(() -> {
126127
ProviderState providerState1 = client.getProviderState();
127128
return providerState1 == providerState;
128129
});

src/test/java/dev/openfeature/sdk/vmlens/VmLensTest.java renamed to src/test/java/dev/openfeature/sdk/vmlens/VmLensCT.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
import org.junit.jupiter.api.BeforeEach;
1919
import org.junit.jupiter.api.Test;
2020

21-
class VmLensTest {
21+
class VmLensCT {
2222
final OpenFeatureAPI api = OpenFeatureAPITestUtil.createAPI();
2323

2424
@BeforeEach

0 commit comments

Comments
 (0)