Skip to content

Commit

Permalink
Sp 1026 (#1027) Fix unit test and activate them in actions
Browse files Browse the repository at this point in the history
* [#1026] Fix unit test in extensions-management

* [#1026] Fix junit tests in streampipes-pipeline-management

* [#1026] Fix junit tests in streampipes-connect-management

* [#1026] Activate JUnit tests in GiHub actions

* [#1026] Remove flinkspector from tests
  • Loading branch information
tenthe committed Jan 3, 2023
1 parent e7fa301 commit 60ebf21
Show file tree
Hide file tree
Showing 65 changed files with 488 additions and 3,174 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
node-version: '16.x'

- name: Build with Maven
run: mvn clean verify -Dmaven.test.skip=true
run: mvn clean verify

- name: Set env variables for Docker builds
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/cypress-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ jobs:
npm run build
- name: Build with Maven
run: mvn clean package -Dmaven.test.skip=true
run: mvn clean package

- name: Build and run streampipes
run: docker-compose up --build -d
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/pr-validation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
java-version: '17'

- name: Validate java code
run: mvn clean verify -Dmaven.test.skip=true
run: mvn clean verify

run-format-and-lint-ui:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -85,7 +85,7 @@ jobs:
npm run build
- name: Build with Maven
run: mvn clean package -Dmaven.test.skip=true
run: mvn clean package

- name: Build and run streampipes
run: docker-compose up --build -d
Expand Down
18 changes: 0 additions & 18 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@
<elasticsearch.version>6.8.17</elasticsearch.version>
<file-management.version>3.1.0</file-management.version>
<flink.version>1.13.5</flink.version>
<flinkspector.version>0.9.4</flinkspector.version>
<fogsy-qudt.version>1.0</fogsy-qudt.version>
<fst.version>2.57</fst.version>
<geojson-jackson.version>1.14</geojson-jackson.version>
Expand Down Expand Up @@ -993,23 +992,6 @@
<version>${rest-assured.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>io.flinkspector</groupId>
<artifactId>flinkspector-datastream_2.11</artifactId>
<version>${flinkspector.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.flink</groupId>
<artifactId>flink-test-utils_2.11</artifactId>
<version>${flink.version}</version>
<exclusions>
<exclusion>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-slf4j-impl</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.apache.flink</groupId>
<artifactId>flink-runtime_2.11</artifactId>
Expand Down
10 changes: 0 additions & 10 deletions streampipes-connect-management/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -79,16 +79,6 @@
<artifactId>mockito-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.powermock</groupId>
<artifactId>powermock-module-junit4</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.powermock</groupId>
<artifactId>powermock-api-mockito2</artifactId>
<scope>test</scope>
</dependency>
</dependencies>

<build>
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@

import org.junit.Test;

import java.util.Arrays;
import java.util.List;

import static org.junit.Assert.assertEquals;
Expand All @@ -49,7 +48,7 @@ public void getAdapterFailNull() throws AdapterException {

@Test(expected = AdapterException.class)
public void getAdapterFail() throws AdapterException {
List<AdapterDescription> adapterDescriptions = Arrays.asList(new GenericAdapterStreamDescription());
List<AdapterDescription> adapterDescriptions = List.of(new GenericAdapterStreamDescription());
AdapterInstanceStorageImpl adapterStorage = mock(AdapterInstanceStorageImpl.class);
AdapterResourceManager resourceManager = mock(AdapterResourceManager.class);
when(adapterStorage.getAllAdapters()).thenReturn(adapterDescriptions);
Expand All @@ -62,7 +61,7 @@ public void getAdapterFail() throws AdapterException {

@Test
public void getAllAdaptersSuccess() throws AdapterException {
List<AdapterDescription> adapterDescriptions = Arrays.asList(new GenericAdapterStreamDescription());
List<AdapterDescription> adapterDescriptions = List.of(new GenericAdapterStreamDescription());
AdapterInstanceStorageImpl adapterStorage = mock(AdapterInstanceStorageImpl.class);
AdapterResourceManager resourceManager = mock(AdapterResourceManager.class);
when(adapterStorage.getAllAdapters()).thenReturn(adapterDescriptions);
Expand Down

This file was deleted.

0 comments on commit 60ebf21

Please sign in to comment.