Commit 556351b0 authored by Matija Obreza's avatar Matija Obreza
Browse files

Introducing glis-client-common module

parent 37a2a4fe
...@@ -6,10 +6,10 @@ ...@@ -6,10 +6,10 @@
<relativePath>..</relativePath> <relativePath>..</relativePath>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<artifactId>glis-client-tests</artifactId> <artifactId>glis-client-common</artifactId>
<packaging>jar</packaging> <packaging>jar</packaging>
<name>GLIS API client tests</name> <name>GLIS API client tests and common code</name>
<description>Tests for GLIS API client</description> <description>Tests and common code for GLIS API client</description>
<properties> <properties>
<org.slf4j.version>1.7.25</org.slf4j.version> <org.slf4j.version>1.7.25</org.slf4j.version>
......
...@@ -26,7 +26,11 @@ ...@@ -26,7 +26,11 @@
<artifactId>swagger-annotations</artifactId> <artifactId>swagger-annotations</artifactId>
<version>${swagger-core.version}</version> <version>${swagger-core.version}</version>
</dependency> </dependency>
<dependency>
<groupId>org.genesys-pgr</groupId>
<artifactId>glis-client-common</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
<!-- HTTP client: jersey-client --> <!-- HTTP client: jersey-client -->
<dependency> <dependency>
<groupId>org.glassfish.jersey.core</groupId> <groupId>org.glassfish.jersey.core</groupId>
...@@ -85,12 +89,6 @@ ...@@ -85,12 +89,6 @@
<version>2.2</version> <version>2.2</version>
</dependency> </dependency>
<!-- test dependencies --> <!-- test dependencies -->
<dependency>
<groupId>org.genesys-pgr</groupId>
<artifactId>glis-client-tests</artifactId>
<version>1.0-SNAPSHOT</version>
<scope>test</scope>
</dependency>
<dependency> <dependency>
<groupId>junit</groupId> <groupId>junit</groupId>
<artifactId>junit</artifactId> <artifactId>junit</artifactId>
......
...@@ -26,6 +26,11 @@ ...@@ -26,6 +26,11 @@
<artifactId>swagger-annotations</artifactId> <artifactId>swagger-annotations</artifactId>
<version>${swagger-core.version}</version> <version>${swagger-core.version}</version>
</dependency> </dependency>
<dependency>
<groupId>org.genesys-pgr</groupId>
<artifactId>glis-client-common</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
<dependency> <dependency>
<groupId>com.squareup.okhttp</groupId> <groupId>com.squareup.okhttp</groupId>
<artifactId>okhttp</artifactId> <artifactId>okhttp</artifactId>
...@@ -42,12 +47,6 @@ ...@@ -42,12 +47,6 @@
<version>${gson-version}</version> <version>${gson-version}</version>
</dependency> </dependency>
<!-- test dependencies --> <!-- test dependencies -->
<dependency>
<groupId>org.genesys-pgr</groupId>
<artifactId>glis-client-tests</artifactId>
<version>1.0-SNAPSHOT</version>
<scope>test</scope>
</dependency>
<dependency> <dependency>
<groupId>junit</groupId> <groupId>junit</groupId>
<artifactId>junit</artifactId> <artifactId>junit</artifactId>
......
...@@ -73,18 +73,6 @@ ...@@ -73,18 +73,6 @@
</sources> </sources>
</configuration> </configuration>
</execution> </execution>
<execution>
<id>add-common-source</id>
<phase>initialize</phase>
<goals>
<goal>add-source</goal>
</goals>
<configuration>
<sources>
<source>../src/common/java</source>
</sources>
</configuration>
</execution>
</executions> </executions>
</plugin> </plugin>
<!-- <plugin> <!-- <plugin>
......
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
</issueManagement> </issueManagement>
<modules> <modules>
<module>tests</module> <module>common</module>
<module>okhttp-gson</module> <module>okhttp-gson</module>
<module>jersey2</module> <module>jersey2</module>
<module>resteasy</module> <module>resteasy</module>
......
...@@ -26,6 +26,11 @@ ...@@ -26,6 +26,11 @@
<artifactId>swagger-annotations</artifactId> <artifactId>swagger-annotations</artifactId>
<version>${swagger-core.version}</version> <version>${swagger-core.version}</version>
</dependency> </dependency>
<dependency>
<groupId>org.genesys-pgr</groupId>
<artifactId>glis-client-common</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
<!-- HTTP client: jersey-client --> <!-- HTTP client: jersey-client -->
<!-- HTTP client: jersey-client --> <!-- HTTP client: jersey-client -->
...@@ -76,12 +81,6 @@ ...@@ -76,12 +81,6 @@
</dependency> </dependency>
<!-- test dependencies --> <!-- test dependencies -->
<dependency>
<groupId>org.genesys-pgr</groupId>
<artifactId>glis-client-tests</artifactId>
<version>1.0-SNAPSHOT</version>
<scope>test</scope>
</dependency>
<dependency> <dependency>
<groupId>junit</groupId> <groupId>junit</groupId>
<artifactId>junit</artifactId> <artifactId>junit</artifactId>
......
...@@ -26,6 +26,11 @@ ...@@ -26,6 +26,11 @@
<artifactId>swagger-annotations</artifactId> <artifactId>swagger-annotations</artifactId>
<version>${swagger-core.version}</version> <version>${swagger-core.version}</version>
</dependency> </dependency>
<dependency>
<groupId>org.genesys-pgr</groupId>
<artifactId>glis-client-common</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
<!-- HTTP client: Spring RestTemplate --> <!-- HTTP client: Spring RestTemplate -->
<dependency> <dependency>
...@@ -75,12 +80,6 @@ ...@@ -75,12 +80,6 @@
<version>${junit-version}</version> <version>${junit-version}</version>
<scope>test</scope> <scope>test</scope>
</dependency> </dependency>
<dependency>
<groupId>org.genesys-pgr</groupId>
<artifactId>glis-client-tests</artifactId>
<version>1.0-SNAPSHOT</version>
<scope>test</scope>
</dependency>
<dependency> <dependency>
<groupId>org.hamcrest</groupId> <groupId>org.hamcrest</groupId>
<artifactId>hamcrest-library</artifactId> <artifactId>hamcrest-library</artifactId>
......
...@@ -26,6 +26,7 @@ import java.util.List; ...@@ -26,6 +26,7 @@ import java.util.List;
import java.util.Set; import java.util.Set;
import java.util.stream.Collectors; import java.util.stream.Collectors;
import org.genesys.glis.v1.TermConstants;
import org.genesys.glis.v1.model.PGRFA; import org.genesys.glis.v1.model.PGRFA;
import org.genesys.glis.v1.model.UpdateTargets; import org.genesys.glis.v1.model.UpdateTargets;
import org.genesys.glis.v1.model.UpdatedTarget; import org.genesys.glis.v1.model.UpdatedTarget;
...@@ -50,7 +51,7 @@ public class GenesysGlisTest extends TestEnvironmentAPITest { ...@@ -50,7 +51,7 @@ public class GenesysGlisTest extends TestEnvironmentAPITest {
if (somePgrfa.size() > 0) { if (somePgrfa.size() > 0) {
assertThat(somePgrfa, hasSize(perPage)); assertThat(somePgrfa, hasSize(perPage));
UpdateTargets targets = new UpdateTargets(); UpdateTargets targets = new UpdateTargets();
targets.addKwsItem("1"); targets.addKwsItem(TermConstants.PASSPORT_DATA);
for (PGRFA pgrfa : somePgrfa) { for (PGRFA pgrfa : somePgrfa) {
targets.addDoisItem(pgrfa.getDoi()); targets.addDoisItem(pgrfa.getDoi());
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment