File tree Expand file tree Collapse file tree 5 files changed +10
-9
lines changed
opennlp-cli/src/test/java/opennlp/tools
opennlp-runtime/src/test/java/opennlp/tools
opennlp-extensions/opennlp-uima/src/test/java/opennlp/uima
opennlp-tools/src/test/java/opennlp/tools/namefind Expand file tree Collapse file tree 5 files changed +10
-9
lines changed Original file line number Diff line number Diff line change @@ -34,8 +34,8 @@ public abstract class AbstractModelLoaderTest {
3434
3535 private static final Logger logger = LoggerFactory .getLogger (AbstractModelLoaderTest .class );
3636
37- private static final String BASE_URL_MODELS_V15 = " https://opennlp.sourceforge.net/models-1.5/" ;
38- private static final String BASE_URL_MODELS_V183 = " https://dlcdn.apache.org/opennlp/models/langdetect/1.8.3/" ;
37+ private static final String BASE_URL_MODELS_V15 = System . getProperty ( "opennlp.model.v15.base.url" , " https://opennlp.sourceforge.net/models-1.5/") ;
38+ private static final String BASE_URL_MODELS_V183 = System . getProperty ( "opennlp.model.v183.base.url" , " https://dlcdn.apache.org/opennlp/models/langdetect/1.8.3/") ;
3939 protected static final Path OPENNLP_DIR = Paths .get (System .getProperty ("OPENNLP_DOWNLOAD_HOME" ,
4040 System .getProperty ("user.home" ))).resolve (".opennlp" );
4141 protected static final String VER = "1.3-2.5.4" ;
Original file line number Diff line number Diff line change @@ -34,8 +34,8 @@ public abstract class AbstractModelLoaderTest {
3434
3535 private static final Logger logger = LoggerFactory .getLogger (AbstractModelLoaderTest .class );
3636
37- private static final String BASE_URL_MODELS_V15 = " https://opennlp.sourceforge.net/models-1.5/" ;
38- private static final String BASE_URL_MODELS_V183 = " https://dlcdn.apache.org/opennlp/models/langdetect/1.8.3/" ;
37+ private static final String BASE_URL_MODELS_V15 = System . getProperty ( "opennlp.model.v15.base.url" , " https://opennlp.sourceforge.net/models-1.5/") ;
38+ private static final String BASE_URL_MODELS_V183 = System . getProperty ( "opennlp.model.v183.base.url" , " https://dlcdn.apache.org/opennlp/models/langdetect/1.8.3/") ;
3939 protected static final Path OPENNLP_DIR = Paths .get (System .getProperty ("OPENNLP_DOWNLOAD_HOME" ,
4040 System .getProperty ("user.home" ))).resolve (".opennlp" );
4141 protected static final String VER = "1.2-2.5.0" ;
Original file line number Diff line number Diff line change @@ -53,8 +53,8 @@ abstract class AbstractIT extends AbstractUimaTest {
5353
5454 protected static final String BIN = ".bin" ;
5555
56- private static final String BASE_URL_MODELS_V15 = " https://opennlp.sourceforge.net/models-1.5/" ;
57-
56+ private static final String BASE_URL_MODELS_V15 = System . getProperty ( "opennlp.model.v15.base.url" , " https://opennlp.sourceforge.net/models-1.5/") ;
57+
5858 @ BeforeAll
5959 public static void initEnv () throws IOException {
6060 // ensure referenced UD models are present in download home
Original file line number Diff line number Diff line change @@ -46,7 +46,7 @@ abstract class AbstractNameFinderTest {
4646 protected static final Path OPENNLP_DIR = Paths .get (System .getProperty ("OPENNLP_DOWNLOAD_HOME" ,
4747 System .getProperty ("user.home" ))).resolve (".opennlp" );
4848
49- private static final String BASE_URL_MODELS_V15 = " https://opennlp.sourceforge.net/models-1.5/" ;
49+ private static final String BASE_URL_MODELS_V15 = System . getProperty ( "opennlp.model.v15.base.url" , " https://opennlp.sourceforge.net/models-1.5/") ;
5050
5151 protected static boolean hasOtherAsOutcome (TokenNameFinderModel nameFinderModel ) {
5252 SequenceClassificationModel model = nameFinderModel .getNameFinderSequenceModel ();
Original file line number Diff line number Diff line change 339339 <groupId >org.apache.maven.plugins</groupId >
340340 <artifactId >maven-surefire-plugin</artifactId >
341341 <configuration >
342- <argLine >-Xmx2048m -Dorg.slf4j.simpleLogger.defaultLogLevel=off</argLine >
342+ <argLine >-Xmx2048m -Dorg.slf4j.simpleLogger.defaultLogLevel=off -Dopennlp.model.v15.base.url=" ${opennlp.model.v15.base.url} " </argLine >
343343 <forkCount >${opennlp.forkCount} </forkCount >
344344 <failIfNoSpecifiedTests >false</failIfNoSpecifiedTests >
345345 <excludes >
364364 </execution >
365365 </executions >
366366 <configuration >
367- <argLine >-DOPENNLP_DOWNLOAD_HOME=${opennlp.download.home} </argLine >
367+ <argLine >-DOPENNLP_DOWNLOAD_HOME=${opennlp.download.home} -Dopennlp.model.v15.base.url=" ${opennlp.model.v15.base.url} " </argLine >
368368 <excludes >
369369 <exclude >**/*Test.java</exclude >
370370 </excludes >
667667 <id >ci</id >
668668 <properties >
669669 <opennlp .download.home>${project.build.directory} </opennlp .download.home>
670+ <opennlp .model.v15.base.url>https://nightlies.apache.org/opennlp/models-1.5/</opennlp .model.v15.base.url>
670671 </properties >
671672 </profile >
672673
You can’t perform that action at this time.
0 commit comments