-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test configuration for components (#286)
* NED-Dandelion 3.2.0 add new properties for caching, token and apiLiveTesting add costume exceptions add RestTemplateWithCaching and CacheOfRestTemplateResponse process method divided into several new methods add tests for LiveAPI, MockedAPI and Caching * NED-Dandelion 3.2.1 removing old test approaches * NED-Dandelion 3.2.2 rename property for global usage * NED-AGDISTIS 4.2.0 split the process method in seperate testeble methods for future testing add RestTemplateWithCache for API call add cache property add cache test * NED-Babelfy 3.2.0 split the process method in seperate testeble methods for future testing add RestTemplateWithCache for API call add cache property add cache test add live test add mocked test * NER-ComicCharacterNameSimpleNamedEntityRecognizer 3.2.0 split the process method in seperate testeble methods for future testing add live test add mocked test * NER-Dandelion 3.2.0 split the process method in seperate testeble methods for future testing add live test add mocked test add cache test * qanary-component-NER-DBpediaSpotlight 3.2.0 add tests update the fetcher, using now restTemplate split the process method in smaller methods * qanary-component-NER-DBpediaSpotlight 3.2.1 some bug fixes * NER-MeaningCloud 3.2.0 add live tests add mocked tests add cache tests split process method in separate methods changed api call to restTemplate (with cache) remove default template bugfix in insert query * NED-Dandelion 3.2.3 change api.key property some code clean up add new solution for cache test * NED-Babelfy 3.2.1 update cache test * NER-Dandelion 3.2.1 update cache test * NER-MeaningCloud 3.2.1 update cache test * NER-TextRazor 3.2.0 split process method in separate methods add exceptions add new properties using RestTemplate for api calls add tests * NED-Babelfy 3.2.2 update property names * NER-Dandelion 3.2.2 update property names * NER-Tagme 3.2.0 split process method in smaller methods add properties add tests * QB-BirthDataWikidata 3.3.0 add tests * QB-ComicCharacterAlterEgoSimpleDBpedia 3.320 add tests * QBE-SimpleQueryBuilderAndExecutor 3.2.0 add tests * QB-ComicCharacterAlterEgoSimpleDBpedia 3.2.0 add tests * QBE-SimpleQueryBuilderAndExecutor 3.2.0 add tests * NED-AGDISTIS 4.2.1 split process method in separate methods add tests * fix of components MeaningCloud and Babelfy * fixed configuration * NER-MeaningCloud 3.2.2 disable question 3 --------- Co-authored-by: anbo-de <[email protected]> Co-authored-by: Andreas Both <[email protected]>
- Loading branch information
1 parent
198135c
commit ec1d12e
Showing
141 changed files
with
8,658 additions
and
1,165 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
304 changes: 214 additions & 90 deletions
304
...omponent-NED-AGDISTIS/src/main/java/eu/wdaqua/qanary/component/agdistis/ned/Agdistis.java
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
83 changes: 83 additions & 0 deletions
83
...ain/java/eu/wdaqua/qanary/component/agdistis/ned/exception/ApiLiveTestFaildException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
package eu.wdaqua.qanary.component.agdistis.ned.exception; | ||
|
||
import java.io.Serial; | ||
import java.security.PrivilegedActionException; | ||
|
||
public class ApiLiveTestFaildException extends Exception { | ||
@Serial | ||
private static final long serialVersionUID = -1975683222057844503L; | ||
|
||
/** | ||
* Constructs a new exception with {@code null} as its detail message. | ||
* The cause is not initialized, and may subsequently be initialized by a | ||
* call to {@link #initCause}. | ||
*/ | ||
public ApiLiveTestFaildException() { | ||
} | ||
|
||
/** | ||
* Constructs a new exception with the specified detail message. The | ||
* cause is not initialized, and may subsequently be initialized by | ||
* a call to {@link #initCause}. | ||
* | ||
* @param message the detail message. The detail message is saved for | ||
* later retrieval by the {@link #getMessage()} method. | ||
*/ | ||
public ApiLiveTestFaildException(String message) { | ||
super(message); | ||
} | ||
|
||
/** | ||
* Constructs a new exception with the specified detail message and | ||
* cause. <p>Note that the detail message associated with | ||
* {@code cause} is <i>not</i> automatically incorporated in | ||
* this exception's detail message. | ||
* | ||
* @param message the detail message (which is saved for later retrieval | ||
* by the {@link #getMessage()} method). | ||
* @param cause the cause (which is saved for later retrieval by the | ||
* {@link #getCause()} method). (A {@code null} value is | ||
* permitted, and indicates that the cause is nonexistent or | ||
* unknown.) | ||
* @since 1.4 | ||
*/ | ||
public ApiLiveTestFaildException(String message, Throwable cause) { | ||
super(message, cause); | ||
} | ||
|
||
/** | ||
* Constructs a new exception with the specified cause and a detail | ||
* message of {@code (cause==null ? null : cause.toString())} (which | ||
* typically contains the class and detail message of {@code cause}). | ||
* This constructor is useful for exceptions that are little more than | ||
* wrappers for other throwables (for example, {@link | ||
* PrivilegedActionException}). | ||
* | ||
* @param cause the cause (which is saved for later retrieval by the | ||
* {@link #getCause()} method). (A {@code null} value is | ||
* permitted, and indicates that the cause is nonexistent or | ||
* unknown.) | ||
* @since 1.4 | ||
*/ | ||
public ApiLiveTestFaildException(Throwable cause) { | ||
super(cause); | ||
} | ||
|
||
/** | ||
* Constructs a new exception with the specified detail message, | ||
* cause, suppression enabled or disabled, and writable stack | ||
* trace enabled or disabled. | ||
* | ||
* @param message the detail message. | ||
* @param cause the cause. (A {@code null} value is permitted, | ||
* and indicates that the cause is nonexistent or unknown.) | ||
* @param enableSuppression whether or not suppression is enabled | ||
* or disabled | ||
* @param writableStackTrace whether or not the stack trace should | ||
* be writable | ||
* @since 1.7 | ||
*/ | ||
public ApiLiveTestFaildException(String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) { | ||
super(message, cause, enableSuppression, writableStackTrace); | ||
} | ||
} |
83 changes: 83 additions & 0 deletions
83
.../java/eu/wdaqua/qanary/component/agdistis/ned/exception/ApiUrlIsNullOrEmptyException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
package eu.wdaqua.qanary.component.agdistis.ned.exception; | ||
|
||
import java.io.Serial; | ||
import java.security.PrivilegedActionException; | ||
|
||
public class ApiUrlIsNullOrEmptyException extends Exception { | ||
@Serial | ||
private static final long serialVersionUID = 7428354571800821878L; | ||
|
||
/** | ||
* Constructs a new exception with {@code null} as its detail message. | ||
* The cause is not initialized, and may subsequently be initialized by a | ||
* call to {@link #initCause}. | ||
*/ | ||
public ApiUrlIsNullOrEmptyException() { | ||
} | ||
|
||
/** | ||
* Constructs a new exception with the specified detail message. The | ||
* cause is not initialized, and may subsequently be initialized by | ||
* a call to {@link #initCause}. | ||
* | ||
* @param message the detail message. The detail message is saved for | ||
* later retrieval by the {@link #getMessage()} method. | ||
*/ | ||
public ApiUrlIsNullOrEmptyException(String message) { | ||
super(message); | ||
} | ||
|
||
/** | ||
* Constructs a new exception with the specified detail message and | ||
* cause. <p>Note that the detail message associated with | ||
* {@code cause} is <i>not</i> automatically incorporated in | ||
* this exception's detail message. | ||
* | ||
* @param message the detail message (which is saved for later retrieval | ||
* by the {@link #getMessage()} method). | ||
* @param cause the cause (which is saved for later retrieval by the | ||
* {@link #getCause()} method). (A {@code null} value is | ||
* permitted, and indicates that the cause is nonexistent or | ||
* unknown.) | ||
* @since 1.4 | ||
*/ | ||
public ApiUrlIsNullOrEmptyException(String message, Throwable cause) { | ||
super(message, cause); | ||
} | ||
|
||
/** | ||
* Constructs a new exception with the specified cause and a detail | ||
* message of {@code (cause==null ? null : cause.toString())} (which | ||
* typically contains the class and detail message of {@code cause}). | ||
* This constructor is useful for exceptions that are little more than | ||
* wrappers for other throwables (for example, {@link | ||
* PrivilegedActionException}). | ||
* | ||
* @param cause the cause (which is saved for later retrieval by the | ||
* {@link #getCause()} method). (A {@code null} value is | ||
* permitted, and indicates that the cause is nonexistent or | ||
* unknown.) | ||
* @since 1.4 | ||
*/ | ||
public ApiUrlIsNullOrEmptyException(Throwable cause) { | ||
super(cause); | ||
} | ||
|
||
/** | ||
* Constructs a new exception with the specified detail message, | ||
* cause, suppression enabled or disabled, and writable stack | ||
* trace enabled or disabled. | ||
* | ||
* @param message the detail message. | ||
* @param cause the cause. (A {@code null} value is permitted, | ||
* and indicates that the cause is nonexistent or unknown.) | ||
* @param enableSuppression whether or not suppression is enabled | ||
* or disabled | ||
* @param writableStackTrace whether or not the stack trace should | ||
* be writable | ||
* @since 1.7 | ||
*/ | ||
public ApiUrlIsNullOrEmptyException(String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) { | ||
super(message, cause, enableSuppression, writableStackTrace); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.