Hi Sean,

You're right. Most of the time, the community doesn't have their own
Jenkins for a cTAKES build. I just find the Jenkins "hardcoding" solution a
little bit unusual for builds.apache.org.

However, the solution I was working on, I decided to get your feedback and
not just commit-ing it. You can find the patch *attached* [1], or on github
for more convenience [2]. Together with the Assume.assumeTrue, I also
removed duplicates for the environment variables usage: "ctakes.uml*". I
have also added to the pom.xml the enforcement for the ctakes.umlsuser to
CHANGE_ME. That means, the one who makes the releases would have to build
with something like:
-Dctakes_umlsuser=<his-user> -Dctakes_umlspw=<his-password>

Committing this patch would make the Jenkins build succeed. I would like to
know what the community thinks about making the changes to the *official
[3] *Jenkins job to be the same as the cTAKES-trunk-Java-1.8 [4]. The later
job has Sonar integration, runs all tests and:

--fail-at-end --errors --update-snapshots clean install

vs

clean compile test


Getting back to your solution, Sean, I am curious how the community is
using cTAKES (integrated or as a dependency) and building cTAKES solutions.

I look forward to your feedback,
Alex

[1] - testCPE.CTAKES-479.svn.patch (see attachment)
[2] - https://github.com/azbarcea/ctakes/commit/
1f460a0e2bc2463d87ca3072a8fa0a3cf2eab69a
[3] - https://builds.apache.org/view/C/view/Apache%20cTAKES/
job/ctakes-trunk-compiletest/
[4] - https://builds.apache.org/view/C/view/Apache%20cTAKES/
job/cTAKES-trunk-Java-1.8/


On Wed, Nov 15, 2017 at 5:10 PM, Finan, Sean <[email protected].
edu> wrote:

> Hi Alex,
>
> I don't know what you mean about making it less portable.  Basically, the
> test would run unless it is on Jenkins.  I don't know how many people are
> mirroring all of ctakes and running their own Jenkins builds, but all it
> means is that the regression test would not run for them.  People that are
> mirroring and running automated builds on something other than Jenkins will
> face the problem that we have now, but in their own environment they can
> set the umls parameters.  Unless it is public ...
>
> As I see it, our problem right now is with Jenkins, so I think that should
> be our focus.  If we (or apache) move to another build/test system then we
> fix it again at that time.  If some other party uses another system then
> they can handle the problem as they see fit.
>
> All that said, you should feel free to tackle this in any manner that you
> like.  I am just offering some thoughts.
>
> Sean
>
> -----Original Message-----
> From: Alexandru Zbarcea [mailto:[email protected]]
> Sent: Wednesday, November 15, 2017 4:54 PM
> To: Apache cTAKES Dev
> Subject: Re: Disable yTEX and Regression tests on Jenkins [EXTERNAL]
>
> Hi Sean,
>
> Glad I'm on the right path with assumeTrue, I will come back shortly with
> a patch for it.
>
> Checking for a buildID, would make cTAKES dependent on the Apache build
> service (Jenkins), making it less portable. I think it would impact
> adoption for community.
>
> What do you think?
> Alex
>
>
> On Wed, Nov 15, 2017 at 1:36 PM, Finan, Sean <
> [email protected]> wrote:
>
> > Hi Alex,
> >
> > I like your assumeTrue idea.  I think that you wrote about it earlier?
> > The only problem that I can think of right now is the different ways
> > that the umls credentials can be supplied.  It may be difficult to
> > check them all.  However, maybe just one being available is all that is
> needed.
> >
> > What about using assumeTrue to check for a Jenkins environment instead
> > of checking for umls credentials?  We could check for a $BUILD_TAG
> > that starts with "jenkins-" and/or $JENKINS_URL.
> >
> > https://urldefense.proofpoint.com/v2/url?u=https-3A__wiki.jenkins.io_d
> > isplay_JENKINS_Building-2Ba-2Bsoftware-2Bproject&d=DwIBaQ&c=qS4goWBT7p
> > oplM69zy_3xhKwEW14JZMSdioCoppxeFU&r=fs67GvlGZstTpyIisCYNYmQCP6r0bcpKGd
> > 4f7d4gTao&m=BqBNyzBBwKSqP3UmlCFHwNAZDxCKhKoPnfSAzfjbGzI&s=_g-gnJ2P16ag
> > tG71SgyhcRItc6p_nRgCzSa1UPdWFXM&e=
> >
> >
> > Don't follow my lead ... we'll both get lost.
> >
> > Sean
> >
> >
> > -----Original Message-----
> > From: Alexandru Zbarcea [mailto:[email protected]]
> > Sent: Wednesday, November 15, 2017 12:41 PM
> > To: Apache cTAKES Dev
> > Subject: Re: Disable yTEX and Regression tests on Jenkins [EXTERNAL]
> >
> > Hi Sean,
> >
> > Your links are very informative. I think using Categories is a great
> idea.
> > Categories can also be used to differentiate between tests that require:
> > DB (MySQL, Oracle, HSQLDB etc) vs non-DB, slow vs fast, UMLS vs non-UMLS.
> >
> > In the solution you propose, if I understand right, the discriminator
> > between running or not running UMLSs tests would be if the category
> > has been added to the default profile. I wonder if it might not create
> > the behavior, for the community, to not run some categories of tests.
> >
> > What I was thinking is to use Assume.assumeTrue [1] (as a side note,
> > it can be used together with Categories ) and ignore the execution of
> > the test if UMLSs account is not setup and enforce to use UMLS if the
> > realease profile is being used. The reason I say this is because when
> > the release is going to be built, the owner will be forced to certify
> that all tests run.
> > Just my $0.02. What we can also do, is to create a PR, and upload the
> > patch, and based on a consensus to apply the patch.
> >
> > I will follow your lead on this. What do you think?
> > Alex
> >
> > [1] -
> > https://urldefense.proofpoint.com/v2/url?u=http-3A__junit.
> > sourceforge.net_javadoc_org_junit_Assume.html-23assumeTrue-28boolean-2
> > 9&d= DwIBaQ&c=qS4goWBT7poplM69zy_3xhKwEW14JZMSdioCoppxeFU&r=
> > fs67GvlGZstTpyIisCYNYmQCP6r0bcpKGd4f7d4gTao&m=K0KP_
> > M1BTpGUsPOHy6q6q78mS9FKvIj6-B7UEjVOUmc&s=K1pRo0hnemAlUChvke7CvCFXgl7z9
> > u
> > zTgm-oVgSUV6k&e=
> >
> > On Wed, Nov 15, 2017 at 10:05 AM, Finan, Sean <
> > [email protected]> wrote:
> >
> > > Hi Alex,
> > >
> > > That might work, but I don't know that playing with the release
> > > profile is the best course of action.  I have found a few other
> > > possibilities.  I am leaning toward #3 (@Category)
> > >
> > > This approach separates tests into two different directories and
> > > profiles.  It requires a good number of pom changes.:
> > > https://urldefense.proofpoint.com/v2/url?u=https-3A__www.testwithspr
> > > in
> > > g.com_lesson_running-2D&d=DwIBaQ&c=qS4goWBT7poplM69zy_3xhKwEW14JZMSd
> > > io
> > > CoppxeFU&r=fs67GvlGZstTpyIisCYNYmQCP6r0bcpKGd4f7d4gTao&m=K0KP_M1BTpG
> > > Us
> > > POHy6q6q78mS9FKvIj6-B7UEjVOUmc&s=IER3aq60g2KOYhWTLp_kCyZBvd4bYMJG0ho
> > > in
> > > OcDAKM&e=
> > > integration-tests-with-maven/
> > > which is an update of this:
> > > https://urldefense.proofpoint.com/v2/url?u=https-3A__www.petrikainul
> > > ai
> > > nen.net_programming_maven_&d=DwIBaQ&c=qS4goWBT7poplM69zy_3xhKwEW14JZ
> > > MS
> > > dioCoppxeFU&r=fs67GvlGZstTpyIisCYNYmQCP6r0bcpKGd4f7d4gTao&m=K0KP_M1B
> > > Tp
> > > GUsPOHy6q6q78mS9FKvIj6-B7UEjVOUmc&s=99_M-9YUyTCzKBrV5A62i_csb1_NgNlS
> > > In
> > > r4UHz1UTQ&e=
> > > integration-testing-with-maven/
> > >
> > > Another approach looks simpler and more straightforward, using
> > > filenames for tests and a profile:
> > > https://urldefense.proofpoint.com/v2/url?u=https-3A__semaphoreci.com
> > > _c
> > > ommunity_tutorials_how-2Dto-2Dsplit-2Djunit-2Dtests-2Din-2Da-2D&d=Dw
> > > IB
> > > aQ&c=qS4goWBT7poplM69zy_3xhKwEW14JZMSdioCoppxeFU&r=fs67GvlGZstTpyIis
> > > CY
> > > NYmQCP6r0bcpKGd4f7d4gTao&m=K0KP_M1BTpGUsPOHy6q6q78mS9FKvIj6-B7UEjVOU
> > > mc &s=RYlK-TTW_2rK8ckOLjw6rhog5KuCPIr6Obe_h523eXg&e=
> > > continuous-integration-environment
> > > Since this could be done with the -regression module alone we
> > > wouldn't need to rename all unit test files in other modules.
> > >
> > > That being said, it looks like junit 4.8 (or earlier?) has @Category
> > > annotations that can be used:
> > > https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_juni
> > > t-
> > > 2Dteam_junit4_wiki_categories&d=DwIBaQ&c=qS4goWBT7poplM69zy_3xhKwEW1
> > > 4J
> > > ZMSdioCoppxeFU&r=fs67GvlGZstTpyIisCYNYmQCP6r0bcpKGd4f7d4gTao&m=K0KP_
> > > M1
> > > BTpGUsPOHy6q6q78mS9FKvIj6-B7UEjVOUmc&s=1WDCmSYL50NCHMSCi6nEYXfYnOoUD
> > > cX
> > > VfWXY89luqaY&e=
> > > slightly reworded ...:
> > > https://urldefense.proofpoint.com/v2/url?u=https-3A__dzone.com_artic
> > > le
> > > s_closer-2Dlook-2Djunit-2Dcategories&d=DwIBaQ&c=qS4goWBT7poplM69zy_3
> > > xh
> > > KwEW14JZMSdioCoppxeFU&r=fs67GvlGZstTpyIisCYNYmQCP6r0bcpKGd4f7d4gTao&
> > > m=
> > > K0KP_M1BTpGUsPOHy6q6q78mS9FKvIj6-B7UEjVOUmc&s=nSAIYioeUSIi17JHmiluKl
> > > q9
> > > aqOZ7g1mKNF-bhpr_UQ&e=
> > >
> > > Any thoughts on these approaches?
> > >
> > > I think that the regression test should be rewritten.  It is pretty
> > > old and doesn't actually test the default clinical pipeline as
> > > executed by bin/ scripts anymore.
> > >
> > > Sean
> > >
> > > -----Original Message-----
> > > From: Alexandru Zbarcea [mailto:[email protected]]
> > > Sent: Tuesday, November 14, 2017 7:47 PM
> > > To: Apache cTAKES Dev
> > > Subject: Re: Disable yTEX and Regression tests on Jenkins [EXTERNAL]
> > >
> > > Hi,
> > >
> > > It seems that the patch for the
> > > org.apache.ctakes.ytex.ConceptDaoTest
> > > was already provided on CTAKES-334.
> > >
> > > Applying the fix passes the test.
> > >
> > > The only test that needs to be fixed seems to be:
> > > RegressionPipelineTest:testCPE. For this, the fix is to export the
> > > UMLS credentials.
> > >
> > > I am currently working on enabling the the test based on the umls
> > > credentials being available and enforcing the execution on a release
> > > profile, which now seems to be disabled:
> > > useReleaseProfile>false</useReleaseProfile
> > >
> > > Any feedback?
> > > Alex
> > >
> > > [1] -
> > > https://urldefense.proofpoint.com/v2/url?u=https-3A__builds.
> > > apache.org_view_C_view_Apache-2520cTAKES_job_ctakes-2Dtrunk-
> > > 2Dcompiletest_1124_org.apache.ctakes-24ctakes-2Dregression-
> > > 2Dtest_testReport_org.apache.ctakes.regression.test_
> > > RegressionPipelineTest_testCPE_&d=DwIBaQ&c=qS4goWBT7poplM69zy_
> > > 3xhKwEW14JZMSdioCoppxeFU&r=fs67GvlGZstTpyIisCYNYmQCP6r0bcpKGd4f7d4gT
> > > ao
> > > &m=
> > > zeyWc75KvsxXPw3cJmG6oF2TBpxrlbOGRwQyh3CZ-eY&s=kgBJTLtXcwxSXuviL2BBBT
> > > -
> > > j5xGFN4uLHQbEkzPeww0&e=
> > >
> > >
> > > On Tue, Nov 14, 2017 at 9:47 AM, Gandhi Rajan Natarajan <
> > > [email protected]> wrote:
> > >
> > > > Hi Alex,
> > > >
> > > > The error we got in ConceptDaoTest is different from yours. We got
> > > > the
> > > > following:
> > > >
> > > > testCreateConceptGraph(org.apache.ctakes.ytex.ConceptDaoTest):
> > > > Unable to initialize group definition. Group resource name
> > > > [classpath*:org/apache/ctakes/ytex/kernelBeanRefContext.xml],
> > > > factory key [kernelApplicationContext]; nested exception is
> > > > org.springframework.beans.factory.BeanCreationException: Error
> > > > creating bean with name 'kernelApplicationContext' defined in URL
> > > > [file:/D:/Gandhi/ArisG/cTAKES/ctakes_src_new%20-%20Copy/ctak
> > > > es-ytex-res/src/main/resources/org/apache/ctakes/
> > > ytex/kernelBeanRefContext.xml]:
> > > > Instantiation of bean failed; nested exception is
> > > > org.springframework.beans.BeanInstantiationException: Could not
> > > > instantiate bean class [org.springframework.context.s
> > > > upport.ClassPathXmlApplicationContext]: Constructor threw
> > > > exception; nested exception is org.springframework.beans.
> > > factory.BeanCreationException:
> > > > Error creating bean with name 'gramMatrixExporter' defined in
> > > > class path resource [org/apache/ctakes/ytex/beans-kernel.xml]:
> > > > Initialization of bean failed; nested exception is
> > > org.springframework.beans.FatalBeanException:
> > > > Failed to obtain BeanInfo for class
> > > > [org.apache.ctakes.ytex.weka.GramMatrixExporterImpl];
> > > > nested exception is java.beans.IntrospectionException: type
> > > > mismatch between read and write methods
> > > >
> > > > Can you do a full build once and try?
> > > >
> > > > Regards,
> > > > Gandhi
> > > >
> > > >
> > > > -----Original Message-----
> > > > From: Finan, Sean [mailto:[email protected]]
> > > > Sent: Tuesday, November 14, 2017 7:36 PM
> > > > To: [email protected]
> > > > Subject: RE: Disable yTEX and Regression tests on Jenkins
> > > > [EXTERNAL]
> > > >
> > > > Hi Alex,
> > > >
> > > > Major kudos for trying to track this down.
> > > >
> > > > I am not sure why you are seeing that particular problem.
> > > > Metadata class should be auto-generated from the type system, and
> > > > it does have the
> > > > getPatientIdentifier() method.
> > > > https://urldefense.proofpoint.com/v2/url?u=https-3A__svn.apache.or
> > > > g_
> > > > re
> > > > pos_asf_ctakes_trunk_ctakes-2Dtype-2Dsy&d=DwIBaQ&c=qS4goWBT7poplM6
> > > > 9z
> > > > y_
> > > > 3xhKwEW14JZMSdioCoppxeFU&r=fs67GvlGZstTpyIisCYNYmQCP6r0bcpKGd4f7d4
> > > > gT
> > > > ao
> > > > &m=zeyWc75KvsxXPw3cJmG6oF2TBpxrlbOGRwQyh3CZ-eY&s=kWkYEuKO59NQE3OMh
> > > > tI
> > > > Yc
> > > > dGfi0U_56Szw8fxzngfm_0&e=
> > > > stem/src/main/resources/org/apache/ctakes/typesystem/types/
> TypeSystem.
> > > > xml
> > > >
> > > > Do you think that it is possible that the jcasgen is not being run
> > > > before the test?  I think that it is run for ctakes-util, which is
> > > > a dependency for all modules.
> > > >
> > > > Regardless, I cannot see where getPatientIdentifier() is used in
> > > > ConceptDaoTest.  I can't see where the class Metadata is used in
> > > > ConceptDaoTest.  From a quick code search, Metadata is only used
> > > > by the class SourceMetadataUtil in core.  SourceMetadataUtil is
> > > > only used by two classes, both in core.  I think that the change
> > > > in test status is actually unrelated to the Metadata checkin.
> > > > That being said, I don't have any good idea about what is causing it.
> > > >
> > > > Thanks,
> > > > Sean
> > > >
> > > > -----Original Message-----
> > > > From: Alexandru Zbarcea [mailto:[email protected]]
> > > > Sent: Monday, November 13, 2017 6:24 PM
> > > > To: Apache cTAKES Dev
> > > > Subject: RE: Disable yTEX and Regression tests on Jenkins
> > > > [EXTERNAL]
> > > >
> > > > Hi,
> > > >
> > > > The official Jenkins job (referenced in the pom.xml) is:
> > > > https://urldefense.proofpoint.com/v2/url?u=https-3A__builds.
> > > > apache.org_job_ctakes-2Dtrunk_&d=DwIBaQ&c=qS4goWBT7poplM69zy
> > > > _3xhKwEW14JZMSdioCoppxeFU&r=fs67GvlGZstTpyIisCYNYmQCP6r0bcpK
> > > > Gd4f7d4gTao&m=l0_Tnqk6P-iMIhPUpRO8RiW-eImTKvJDGishYy1Jk-o&s=
> > > > ul6gCHWXUReDCZccgemrhL9EEFs0Id7WilYITMNr5yw&e=. As one may notice,
> > > > the status is Unstable. I was working on the cTAKES-trunk-Java-1.8
> > > > Jenkins job [1] to try to fix the issues there. As such the tests
> > > > failed can be found here [2].
> > > >
> > > > So trying to fix one by one, I discovered that for
> > > > ctakes-ytex:ConceptDaoTest.java:testCreateConceptGraph:
> > > >
> > > > There is the construction:
> > > > metadata.getPatientIdentifier()
> > > > (where metadata:org.apache.ctakes.typesystem.type.structured.
> > Metadata).
> > > >
> > > > Researching where this comes (because it seems it is a new issue),
> > > > I realized that is related to:
> > > > ctakes-type-system/target/generated-sources/jcasgen/org/apac
> > > > he/ctakes/typesystem/type/structured/Metadata.java
> > > > :75:  public String getPatientIdentifier() {
> > > >
> > > > more:
> > > > https://urldefense.proofpoint.com/v2/url?u=https-3A__github.
> > > > com_apache_ctakes_commit_bcdc25420eede623a0889b1db26e1307a2b
> > > > 193bf&d=DwIBaQ&c=qS4goWBT7poplM69zy_3xhKwEW14JZMSdioCoppxeFU
> > > > &r=fs67GvlGZstTpyIisCYNYmQCP6r0bcpKGd4f7d4gTao&m=l0_Tnqk6P-i
> > > > MIhPUpRO8RiW-eImTKvJDGishYy1Jk-o&s=c2oayQ5_G3YgHT5iX9AJw9kuh
> > > > Ir94bFRZ7nxj3ebpuw&e=
> > > > (10 Oct 2017)
> > > >
> > > > I thought that it will be a quick fix just replacing:
> > > >
> > > > metadata.getPatientIdentifier()
> > > >
> > > > with
> > > >
> > > > String.format("%d", metadata.getPatientID());
> > > >
> > > >
> > > > Any feedback?
> > > > Alex
> > > >
> > > > [1] -
> > > > https://urldefense.proofpoint.com/v2/url?u=https-3A__builds.
> > > > apache.org_view_C_view_Apache-2520cTAKES_job_cTAKES-2Dtrunk-
> > > > 2DJava-2D1.8_&d=DwIBaQ&c=qS4goWBT7poplM69zy_3xhKwEW14JZMSdio
> > > > CoppxeFU&r=fs67GvlGZstTpyIisCYNYmQCP6r0bcpKGd4f7d4gTao&m=l0_
> > > > Tnqk6P-iMIhPUpRO8RiW-eImTKvJDGishYy1Jk-o&s=aRH4KLtGndnC-b7UT
> > > > dMqjej6vTDKxavocQwUokE6EHw&e=
> > > > [2] -
> > > > https://urldefense.proofpoint.com/v2/url?u=https-3A__builds.
> > > > apache.org_view_C_view_Apache-2520cTAKES_job_cTAKES-2Dtrunk-
> > > > 2DJava-2D1.8_25_testReport_&d=DwIBaQ&c=qS4goWBT7poplM69zy_3x
> > > > hKwEW14JZMSdioCoppxeFU&r=fs67GvlGZstTpyIisCYNYmQCP6r0bcpKGd4
> > > > f7d4gTao&m=l0_Tnqk6P-iMIhPUpRO8RiW-eImTKvJDGishYy1Jk-o&s=-Pw
> > > > jGWv5MEFT_1Jui9b27fdgkKfFRa29hts-FMalo8I&e=
> > > >
> > > >
> > > > On Nov 13, 2017 10:41, "Finan, Sean"
> > > > <[email protected]>
> > > > wrote:
> > > >
> > > > > Thanks Gandhi!
> > > > >
> > > > > -----Original Message-----
> > > > > From: Gandhi Rajan Natarajan
> > > > > [mailto:[email protected]]
> > > > > Sent: Monday, November 13, 2017 10:40 AM
> > > > > To: [email protected]
> > > > > Subject: RE: Disable yTEX and Regression tests on Jenkins
> > > > > [EXTERNAL]
> > > > >
> > > > > Hi All,
> > > > >
> > > > > We had a look at ctakes-Ytex module's failing test cases and
> > > > > looks like it will not have an impact once we upgrade Spring 4x in
> cTAKES.
> > > > >
> > > > > We will have a run through at other modules and check the
> > > > > failing test cases if any.
> > > > >
> > > > > Regards,
> > > > > Gandhi
> > > > >
> > > > >
> > > > > -----Original Message-----
> > > > > From: Sandeep Byatha Gururaja rao
> > > > > [mailto:[email protected]]
> > > > > Sent: Monday, November 13, 2017 6:50 PM
> > > > > To: [email protected]
> > > > > Subject: RE: Disable yTEX and Regression tests on Jenkins
> > > > > [EXTERNAL]
> > > > >
> > > > > Hi Sean,
> > > > >
> > > > > Myself and Gandhi will work on this and try to fix the issues.
> > > > >
> > > > > Regards,
> > > > > Sandeep
> > > > >
> > > > > ------------------------------------
> > > > >
> > > > > Hi Gandhi,
> > > > >
> > > > > Many thanks for volunteering.  I am slammed with work right now,
> > > > > but if anybody else can also help out ...
> > > > >
> > > > > Sean
> > > > >
> > > > > -----Original Message-----
> > > > > From: Gandhi Rajan Natarajan
> > > > > [mailto:[email protected]]
> > > > > Sent: Thursday, November 09, 2017 12:43 AM
> > > > > To: [email protected]
> > > > > Subject: RE: Disable yTEX and Regression tests on Jenkins
> > > > > [EXTERNAL]
> > > > >
> > > > > Hi Sean,
> > > > >
> > > > > I can take it up if someone is willing to guide me on this.
> > > > >
> > > > > Regards,
> > > > > Gandhi
> > > > >
> > > > >
> > > > > -----Original Message-----
> > > > > From: Finan, Sean [mailto:[email protected]]
> > > > > Sent: Wednesday, November 08, 2017 9:45 PM
> > > > > To: [email protected]
> > > > > Subject: Disable yTEX and Regression tests on Jenkins
> > > > >
> > > > > Hi all,
> > > > >
> > > > > The Jenkins builds have been failing for about a month now
> > > > > because of internal Jenkins changes and 'unit' tests in the
> > > > > ctakes-Regression and ctakes-yTEX modules.  This is holding up
> > > > > the build for all of our primary clinical-pipeline modules.
> > > > >
> > > > > If anybody can take a look at the problems and fix them please
> > > > > respond to this email.  Otherwise I would like to create a jira
> > > > > issue and disable them until somebody does have the time to take
> > > > > care
> > > of them.
> > > > > If you have a good reason for these tests not being disabled (e.g.
> > > > > we might forget to fix
> > > > > them) please state a case.  I do not intend to act unilaterally
> > > > > on this issue.
> > > > >
> > > > > Please respond by midnight Friday, November 10.
> > > > >
> > > > > Thank you,
> > > > >
> > > > > Sean
> > > > > This email and any files transmitted with it are confidential
> > > > > and intended solely for the use of the individual or entity to
> > > > > whom they are
> > > > addressed.
> > > > > If you are not the named addressee you should not disseminate,
> > > > > distribute or copy this e-mail. Please notify the sender or
> > > > > system manager by email immediately if you have received this
> > > > > e-mail by mistake and delete this e-mail from your system. If
> > > > > you are not the intended recipient you are notified that
> > > > > disclosing, copying, distributing or taking any action in
> > > > > reliance on the contents of this information is strictly
> prohibited and against the law.
> > > > >
> > > > > This email and any files transmitted with it are confidential
> > > > > and intended solely for the use of the individual or entity to
> > > > > whom they are
> > > > addressed.
> > > > > If you are not the named addressee you should not disseminate,
> > > > > distribute or copy this e-mail. Please notify the sender or
> > > > > system manager by email immediately if you have received this
> > > > > e-mail by mistake and delete this e-mail from your system. If
> > > > > you are not the intended recipient you are notified that
> > > > > disclosing, copying, distributing or taking any action in
> > > > > reliance on the contents of this information is strictly
> prohibited and against the law.
> > > > > This email and any files transmitted with it are confidential
> > > > > and intended solely for the use of the individual or entity to
> > > > > whom they are
> > > > addressed.
> > > > > If you are not the named addressee you should not disseminate,
> > > > > distribute or copy this e-mail. Please notify the sender or
> > > > > system manager by email immediately if you have received this
> > > > > e-mail by mistake and delete this e-mail from your system. If
> > > > > you are not the intended recipient you are notified that
> > > > > disclosing, copying, distributing or taking any action in
> > > > > reliance on the contents of this information is strictly
> prohibited and against the law.
> > > > >
> > > > This email and any files transmitted with it are confidential and
> > > > intended solely for the use of the individual or entity to whom
> > > > they are
> > > addressed.
> > > > If you are not the named addressee you should not disseminate,
> > > > distribute or copy this e-mail. Please notify the sender or system
> > > > manager by email immediately if you have received this e-mail by
> > > > mistake and delete this e-mail from your system. If you are not
> > > > the intended recipient you are notified that disclosing, copying,
> > > > distributing or taking any action in reliance on the contents of
> > > > this information is strictly prohibited and against the law.
> > > >
> > >
> >
>
diff --git ctakes-core/src/main/java/org/apache/ctakes/core/ae/UmlsEnvironmentConfiguration.java ctakes-core/src/main/java/org/apache/ctakes/core/ae/UmlsEnvironmentConfiguration.java
new file mode 100644
index 00000000..3ab18207
--- /dev/null
+++ ctakes-core/src/main/java/org/apache/ctakes/core/ae/UmlsEnvironmentConfiguration.java
@@ -0,0 +1,29 @@
+package org.apache.ctakes.core.ae;
+
+
+public enum UmlsEnvironmentConfiguration {
+	URL {
+		@Override
+		public String toString() {
+			return "ctakes.umlsaddr";
+		}
+	},
+	VENDOR {
+		@Override
+		public String toString() {
+			return "ctakes.umlsvendor";
+		}
+	},
+	USER {
+		@Override
+		public String toString() {
+			return "ctakes.umlsuser";
+		}
+	},
+	PASSWORD {
+		@Override
+		public String toString() {
+			return "ctakes.umlspw";
+		}
+	}
+}
diff --git ctakes-dictionary-lookup-fast/src/main/java/org/apache/ctakes/dictionary/lookup2/util/UmlsUserApprover.java ctakes-dictionary-lookup-fast/src/main/java/org/apache/ctakes/dictionary/lookup2/util/UmlsUserApprover.java
index 5845b361..29f704b3 100644
--- ctakes-dictionary-lookup-fast/src/main/java/org/apache/ctakes/dictionary/lookup2/util/UmlsUserApprover.java
+++ ctakes-dictionary-lookup-fast/src/main/java/org/apache/ctakes/dictionary/lookup2/util/UmlsUserApprover.java
@@ -18,6 +18,7 @@
  */
 package org.apache.ctakes.dictionary.lookup2.util;
 
+import org.apache.ctakes.core.ae.UmlsEnvironmentConfiguration;
 import org.apache.ctakes.core.util.DotLogger;
 import org.apache.ctakes.utils.env.EnvironmentVariable;
 import org.apache.log4j.Logger;
@@ -58,12 +59,6 @@ public enum UmlsUserApprover {
    public final static String USER_PARAM = "umlsUser";
    public final static String PASS_PARAM = "umlsPass";
 
-   // environment, matches old
-   private final static String UMLSADDR_PARAM = "ctakes.umlsaddr";
-   private final static String UMLSVENDOR_PARAM = "ctakes.umlsvendor";
-   final static String UMLSUSER_PARAM = "ctakes.umlsuser";
-   final static String UMLSPW_PARAM = "ctakes.umlspw";
-
    static final private Logger LOGGER = Logger.getLogger( "UmlsUserApprover" );
 
    static final private String CHANGEME = "CHANGEME";
@@ -80,22 +75,22 @@ public enum UmlsUserApprover {
     * @return true if the server at umlsaddr approves of the vendor, user, password combination
     */
    public boolean isValidUMLSUser( final UimaContext uimaContext, final Properties properties ) {
-      String umlsUrl = EnvironmentVariable.getEnv( UMLSADDR_PARAM, uimaContext );
+      String umlsUrl = EnvironmentVariable.getEnv( UmlsEnvironmentConfiguration.URL.toString(), uimaContext );
       if ( umlsUrl == null || umlsUrl.equals( EnvironmentVariable.NOT_PRESENT ) ) {
          umlsUrl = properties.getProperty( URL_PARAM );
       }
-      String vendor = EnvironmentVariable.getEnv( UMLSVENDOR_PARAM, uimaContext );
+      String vendor = EnvironmentVariable.getEnv( UmlsEnvironmentConfiguration.VENDOR.toString(), uimaContext );
       if ( vendor == null || vendor.equals( EnvironmentVariable.NOT_PRESENT ) ) {
          vendor = properties.getProperty( VENDOR_PARAM );
       }
-      String user = EnvironmentVariable.getEnv( UMLSUSER_PARAM, uimaContext );
+      String user = EnvironmentVariable.getEnv( UmlsEnvironmentConfiguration.USER.toString(), uimaContext );
       if ( user == null || user.equals( EnvironmentVariable.NOT_PRESENT ) || user.equals( CHANGEME ) || user.equals( CHANGE_ME ) ) {
          user = EnvironmentVariable.getEnv( USER_PARAM, uimaContext );
          if ( user == null || user.equals( EnvironmentVariable.NOT_PRESENT ) || user.equals( CHANGEME ) || user.equals( CHANGE_ME ) ) {
             user = properties.getProperty( USER_PARAM );
          }
       }
-      String pass = EnvironmentVariable.getEnv( UMLSPW_PARAM, uimaContext );
+      String pass = EnvironmentVariable.getEnv( UmlsEnvironmentConfiguration.PASSWORD.toString(), uimaContext );
       if ( pass == null || pass.equals( EnvironmentVariable.NOT_PRESENT ) || pass.equals( CHANGEME ) || pass.equals( CHANGE_ME ) ) {
          pass = EnvironmentVariable.getEnv( PASS_PARAM, uimaContext );
          if ( pass == null || pass.equals( EnvironmentVariable.NOT_PRESENT ) || pass.equals( CHANGEME ) || pass.equals( CHANGE_ME ) ) {
@@ -189,17 +184,16 @@ public enum UmlsUserApprover {
       }
    }
 
+   static private String createLogMessage(String cliOption, String property, UmlsEnvironmentConfiguration envConfig) {
+      return String.format(" Verify that you are setting command-line option %s, or ctakes property %s, or environment variable %s properly.",
+              cliOption, property, envConfig);
+   }
 
    static private void logCheckUser() {
-      LOGGER.error( "   Verify that you are setting command-line option " + USER_CLI
-            + " or ctakes property " + USER_PARAM
-            + " or environment variable " + UMLSUSER_PARAM + " properly." );
+      LOGGER.error( createLogMessage(USER_CLI, USER_PARAM, UmlsEnvironmentConfiguration.USER) );
    }
 
    static private void logCheckPass() {
-      LOGGER.error( "   Verify that you are setting command-line option " + PASS_CLI
-            + " or ctakes property " + PASS_PARAM
-            + " or environment variable " + UMLSPW_PARAM + " properly." );
+      LOGGER.error( createLogMessage(PASS_CLI, PASS_PARAM, UmlsEnvironmentConfiguration.PASSWORD) );
    }
-
 }
diff --git ctakes-dictionary-lookup-fast/src/test/java/org/apache/ctakes/dictionary/lookup2/util/UmlsUserTester.java ctakes-dictionary-lookup-fast/src/test/java/org/apache/ctakes/dictionary/lookup2/util/UmlsUserTester.java
index d915356e..8cb21233 100644
--- ctakes-dictionary-lookup-fast/src/test/java/org/apache/ctakes/dictionary/lookup2/util/UmlsUserTester.java
+++ ctakes-dictionary-lookup-fast/src/test/java/org/apache/ctakes/dictionary/lookup2/util/UmlsUserTester.java
@@ -1,11 +1,9 @@
 package org.apache.ctakes.dictionary.lookup2.util;
 
+import org.apache.ctakes.core.ae.UmlsEnvironmentConfiguration;
 import org.apache.ctakes.utils.env.EnvironmentVariable;
 import org.apache.log4j.Logger;
 
-import static org.apache.ctakes.dictionary.lookup2.util.UmlsUserApprover.UMLSPW_PARAM;
-import static org.apache.ctakes.dictionary.lookup2.util.UmlsUserApprover.UMLSUSER_PARAM;
-
 /**
  * @author SPF , chip-nlp
  * @version %I%
@@ -19,11 +17,11 @@ final public class UmlsUserTester {
    }
 
    static public boolean canTestUmlsUser() {
-      String user = EnvironmentVariable.getEnv( UMLSUSER_PARAM, null );
+      String user = EnvironmentVariable.getEnv(UmlsEnvironmentConfiguration.USER.toString());
       if ( user == null || user.equals( EnvironmentVariable.NOT_PRESENT ) ) {
          return false;
       }
-      String pass = EnvironmentVariable.getEnv( UMLSPW_PARAM, null );
+      String pass = EnvironmentVariable.getEnv( UmlsEnvironmentConfiguration.PASSWORD.toString());
       return pass != null && !pass.equals( EnvironmentVariable.NOT_PRESENT );
    }
 
diff --git ctakes-dictionary-lookup/src/main/java/org/apache/ctakes/dictionary/lookup/ae/ThreadedUmlsDictionaryLookupAnnotator.java ctakes-dictionary-lookup/src/main/java/org/apache/ctakes/dictionary/lookup/ae/ThreadedUmlsDictionaryLookupAnnotator.java
index ccc1e17d..4260f3d7 100644
--- ctakes-dictionary-lookup/src/main/java/org/apache/ctakes/dictionary/lookup/ae/ThreadedUmlsDictionaryLookupAnnotator.java
+++ ctakes-dictionary-lookup/src/main/java/org/apache/ctakes/dictionary/lookup/ae/ThreadedUmlsDictionaryLookupAnnotator.java
@@ -18,6 +18,7 @@
  */
 package org.apache.ctakes.dictionary.lookup.ae;
 
+import org.apache.ctakes.core.ae.UmlsEnvironmentConfiguration;
 import org.apache.ctakes.utils.env.EnvironmentVariable;
 import org.apache.log4j.Logger;
 import org.apache.uima.UimaContext;
@@ -37,23 +38,17 @@ import java.net.URLEncoder;
  */
 public class ThreadedUmlsDictionaryLookupAnnotator extends ThreadedDictionaryLookupAnnotator {
 
-   private final static String UMLSADDR_PARAM = "ctakes.umlsaddr";
-   private final static String UMLSVENDOR_PARAM = "ctakes.umlsvendor";
-   private final static String UMLSUSER_PARAM = "ctakes.umlsuser";
-   private final static String UMLSPW_PARAM = "ctakes.umlspw";
-   static final private Logger LOGGER = Logger.getLogger( "ThreadedUmlsDictionaryLookupAnnotator" );
-
-   final private Logger _logger = Logger.getLogger( getClass().getName() );
-
+   // TODO: use consistent variable names (_logger vs LOGGER vs logger)
+   static final private Logger _logger = Logger.getLogger( ThreadedUmlsDictionaryLookupAnnotator.class );
 
    @Override
    public void initialize( final UimaContext aContext ) throws ResourceInitializationException {
       super.initialize( aContext );
-      final String umlsAddress = EnvironmentVariable.getEnv( UMLSADDR_PARAM, aContext );
-      final String umlsVendor = EnvironmentVariable.getEnv( UMLSVENDOR_PARAM, aContext );
-      final String umlsUser = EnvironmentVariable.getEnv( UMLSUSER_PARAM, aContext );
-      final String umlsPassword = EnvironmentVariable.getEnv( UMLSPW_PARAM, aContext );
-      _logger.info( "Using " + UMLSADDR_PARAM + ": " + umlsAddress + ": " + umlsUser );
+      final String umlsAddress = EnvironmentVariable.getEnv(UmlsEnvironmentConfiguration.URL.toString(), aContext );
+      final String umlsVendor = EnvironmentVariable.getEnv( UmlsEnvironmentConfiguration.VENDOR.toString(), aContext );
+      final String umlsUser = EnvironmentVariable.getEnv( UmlsEnvironmentConfiguration.USER.toString(), aContext );
+      final String umlsPassword = EnvironmentVariable.getEnv( UmlsEnvironmentConfiguration.PASSWORD.toString(), aContext );
+      _logger.info( "Using " + UmlsEnvironmentConfiguration.URL + ": " + umlsAddress + ": " + umlsUser );
       if ( !isValidUMLSUser( umlsAddress, umlsVendor, umlsUser, umlsPassword ) ) {
          _logger.error( "Error: Invalid UMLS License.  " +
                         "A UMLS License is required to use the UMLS dictionary lookup. \n" +
@@ -72,7 +67,7 @@ public class ThreadedUmlsDictionaryLookupAnnotator extends ThreadedDictionaryLoo
          data += "&" + URLEncoder.encode( "user", "UTF-8" ) + "=" + URLEncoder.encode( username, "UTF-8" );
          data += "&" + URLEncoder.encode( "password", "UTF-8" ) + "=" + URLEncoder.encode( password, "UTF-8" );
       } catch ( UnsupportedEncodingException unseE ) {
-         LOGGER.error( "Could not encode URL for " + username + " with vendor license " + vendor );
+         _logger.error( "Could not encode URL for " + username + " with vendor license " + vendor );
          return false;
       }
       try {
@@ -99,7 +94,7 @@ public class ThreadedUmlsDictionaryLookupAnnotator extends ThreadedDictionaryLoo
             return result;
          }
       } catch ( IOException ioE ) {
-         LOGGER.error( ioE.getMessage() );
+         _logger.error( ioE.getMessage() );
          return false;
       }
    }
diff --git ctakes-dictionary-lookup/src/main/java/org/apache/ctakes/dictionary/lookup/ae/UmlsDictionaryLookupAnnotator.java ctakes-dictionary-lookup/src/main/java/org/apache/ctakes/dictionary/lookup/ae/UmlsDictionaryLookupAnnotator.java
index 4bbca53e..5bc1e3c9 100644
--- ctakes-dictionary-lookup/src/main/java/org/apache/ctakes/dictionary/lookup/ae/UmlsDictionaryLookupAnnotator.java
+++ ctakes-dictionary-lookup/src/main/java/org/apache/ctakes/dictionary/lookup/ae/UmlsDictionaryLookupAnnotator.java
@@ -19,6 +19,7 @@
 package org.apache.ctakes.dictionary.lookup.ae;
 
 import org.apache.commons.io.FileUtils;
+import org.apache.ctakes.core.ae.UmlsEnvironmentConfiguration;
 import org.apache.ctakes.core.pipeline.PipeBitInfo;
 import org.apache.ctakes.core.resource.FileResourceImpl;
 import org.apache.ctakes.core.resource.JdbcConnectionResourceImpl;
@@ -57,10 +58,6 @@ public class UmlsDictionaryLookupAnnotator extends DictionaryLookupAnnotator {
     * Performs a check for user's UMLS licence at init time via their RESTful API
     * User's will need to configure their UMLS username/password in their config
     */
-   public final static String UMLSADDR_PARAM = "ctakes.umlsaddr";
-   public final static String UMLSVENDOR_PARAM = "ctakes.umlsvendor";
-   public final static String UMLSUSER_PARAM = "ctakes.umlsuser";
-   public final static String UMLSPW_PARAM = "ctakes.umlspw";
 
    private Logger iv_logger = Logger.getLogger( getClass().getName() );
 
@@ -75,12 +72,12 @@ public class UmlsDictionaryLookupAnnotator extends DictionaryLookupAnnotator {
       super.initialize( aContext );
 
       try {
-         UMLSAddr = EnvironmentVariable.getEnv( UMLSADDR_PARAM, aContext );
-         UMLSVendor = EnvironmentVariable.getEnv( UMLSVENDOR_PARAM, aContext );
-         UMLSUser = EnvironmentVariable.getEnv( UMLSUSER_PARAM, aContext );
-         UMLSPW = EnvironmentVariable.getEnv( UMLSPW_PARAM, aContext );
+         UMLSAddr = EnvironmentVariable.getEnv(UmlsEnvironmentConfiguration.URL.toString(), aContext );
+         UMLSVendor = EnvironmentVariable.getEnv( UmlsEnvironmentConfiguration.VENDOR.toString(), aContext );
+         UMLSUser = EnvironmentVariable.getEnv( UmlsEnvironmentConfiguration.USER.toString(), aContext );
+         UMLSPW = EnvironmentVariable.getEnv( UmlsEnvironmentConfiguration.PASSWORD.toString(), aContext );
 
-         iv_logger.info( "Using " + UMLSADDR_PARAM + ": " + UMLSAddr + ": " + UMLSUser );
+         iv_logger.info( "Using " + UmlsEnvironmentConfiguration.URL + ": " + UMLSAddr + ": " + UMLSUser );
          if ( !isValidUMLSUser( UMLSAddr, UMLSVendor, UMLSUser, UMLSPW ) ) {
             iv_logger.error(
                   "Error: Invalid UMLS License.  A UMLS License is required to use the UMLS dictionary lookup. \n" +
@@ -133,9 +130,9 @@ public class UmlsDictionaryLookupAnnotator extends DictionaryLookupAnnotator {
           throw new RuntimeException("Error copying temporary InpuStream org/apache/ctakes/dictionary/lookup/LookupDesc_Db.xml to /tmp/LookupDesc_Db.xml.", e);
       }
       return AnalysisEngineFactory.createEngineDescription( UmlsDictionaryLookupAnnotator.class,
-             UMLSADDR_PARAM,
+             UmlsEnvironmentConfiguration.URL,
              "https://uts-ws.nlm.nih.gov/restful/isValidUMLSUser";,
-             UMLSVENDOR_PARAM,
+             UmlsEnvironmentConfiguration.VENDOR,
              "NLM-6515182895",
              "LookupDescriptor",
              ExternalResourceFactory.createExternalResourceDescription(
diff --git ctakes-regression-test/src/test/java/org/apache/ctakes/regression/test/RegressionPipelineTest.java ctakes-regression-test/src/test/java/org/apache/ctakes/regression/test/RegressionPipelineTest.java
index b7c01949..5e6c6136 100644
--- ctakes-regression-test/src/test/java/org/apache/ctakes/regression/test/RegressionPipelineTest.java
+++ ctakes-regression-test/src/test/java/org/apache/ctakes/regression/test/RegressionPipelineTest.java
@@ -1,23 +1,8 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
 package org.apache.ctakes.regression.test;
 
+import org.apache.commons.io.FilenameUtils;
+import org.apache.ctakes.core.ae.UmlsEnvironmentConfiguration;
+import org.apache.ctakes.utils.env.EnvironmentVariable;
 import org.apache.log4j.Logger;
 import org.apache.uima.UIMAFramework;
 import org.apache.uima.cas.CAS;
@@ -28,9 +13,7 @@ import org.apache.uima.collection.metadata.CpeDescription;
 import org.apache.uima.util.XMLInputSource;
 import org.custommonkey.xmlunit.Diff;
 import org.custommonkey.xmlunit.IgnoreTextAndAttributeValuesDifferenceListener;
-import org.custommonkey.xmlunit.XMLTestCase;
-import org.junit.Assert;
-import org.junit.Test;
+import org.junit.*;
 import org.w3c.dom.Document;
 import org.xml.sax.SAXException;
 
@@ -41,51 +24,35 @@ import java.io.File;
 import java.io.IOException;
 import java.util.List;
 
-/**
- * Runs a full pipeline and compares the xml output to ensure all annotators
- * work together in harmony.
- * 
- * This is designed to run all CPE's inside the
- * desc/collection_processing_engine Directory. So any new pipeline added there
- * will automatically be run and tested as long as they put the generated output
- * to expectedoutput/{nameofcpe}
- * 
- * The Apache cTAKES Release Manager should ensure that at a min this test
- * passes before releasing.
- * 
- * If there are new modules, be sure to add the desc here. If there are changes,
- * after it's been manually reviewed, re-record the expected output and put them
- * in output folder.
- * 
- * This also tests the UMLS annotator(s) so be sure to download the UMLS
- * Resources per README and add the jvm params -Dctakes.umlsuser=
- * -Dctakes.umlspw= parameters before running
- * 
- */
-public class RegressionPipelineTest extends XMLTestCase {
+public class RegressionPipelineTest {
 
+	static Logger logger = Logger.getLogger(RegressionPipelineTest.class.getName());
+
+	// MAX timeout for the CPE
 	private static final int MAX_TIMEOUT_MS = 60 * 60 * 1000; // 60 mins
-	// LOG4J logger based on class name
-	Logger logger = Logger.getLogger(getClass().getName());
-	private static final File CPEDIR = new File(
-			"desc/collection_processing_engine");
-	int num_cpe = 0;
+	// TODO: consider refactor
+	private int num_cpe = 0;
+
+	private static final Boolean hasUMLSCredentials() {
+		return EnvironmentVariable.getEnv(UmlsEnvironmentConfiguration.USER.toString()) != null;
+	}
 
+	@BeforeClass
+	public static void beforeClass() {
+		Assume.assumeTrue( hasUMLSCredentials() );
+	}
 
 	@Test
 	public void testCPE() throws Exception {
 		long started = System.currentTimeMillis();
-		File[] listOfFiles = CPEDIR.listFiles();
+		File directoryCPE = new File("desc/collection_processing_engine");
+		File[] listOfFiles = directoryCPE.listFiles();
 		for (File file : listOfFiles) {
 
 			if (file.isFile()) {
 				num_cpe++;
-				File generated = new File("testdata/generatedoutput/"
-						+ file.getName().substring(0,
-								file.getName().indexOf(".")));
-				File expected = new File("testdata/expectedoutput/"
-						+ file.getName().substring(0,
-								file.getName().indexOf(".")));
+				File generated = new File(String.format("testdata/generatedoutput/%s", FilenameUtils.removeExtension(file.getName())));
+				File expected = new File(String.format("testdata/expectedoutput/%s", FilenameUtils.removeExtension(file.getName())));
 
 				logger.info("Creating directory: " + generated);
 
@@ -100,8 +67,7 @@ public class RegressionPipelineTest extends XMLTestCase {
 				CollectionProcessingEngine mCPE = UIMAFramework
 						.produceCollectionProcessingEngine(cpeDesc);
 				// Create and register a Status Callback Listener
-				mCPE.addStatusCallbackListener(new StatusCallbackListenerImpl(
-						expected, generated));
+				mCPE.addStatusCallbackListener(new RegressionPipelineTest.StatusCallbackListenerImpl(expected, generated));
 				mCPE.process();
 			}
 		}
@@ -109,8 +75,7 @@ public class RegressionPipelineTest extends XMLTestCase {
 		// Before comparing.
 		while (num_cpe > 0) {
 			if (System.currentTimeMillis() - started >= MAX_TIMEOUT_MS) {
-				Assert.assertEquals("Timed out:", "Regression CPE test timed out after "
-						+ MAX_TIMEOUT_MS + " ms");
+				Assert.assertEquals("Timed out:", String.format("Regression CPE test timed out after %d ms", MAX_TIMEOUT_MS));
 			}
 			Thread.sleep(1000);
 		}
@@ -144,16 +109,15 @@ public class RegressionPipelineTest extends XMLTestCase {
 				// myDiff.overrideElementQualifier(new
 				// ElementNameAndAttributeQualifier("id"));
 				myDiff.overrideDifferenceListener(new IgnoreTextAndAttributeValuesDifferenceListener());
-				assertTrue("Verifying Test Output: " + file.getName() + myDiff,
-						myDiff.similar());
+				Assert.assertTrue(String.format("Verifying Test Output: %s%s", file.getName(), myDiff), myDiff.similar());
 			}
 		}
 	}
 
 	/**
 	 * Callback Listener. Receives event notifications from CPE.
-	 * 
-	 * 
+	 *
+	 *
 	 */
 	class StatusCallbackListenerImpl implements StatusCallbackListener {
 		int entityCount = 0;
@@ -168,7 +132,7 @@ public class RegressionPipelineTest extends XMLTestCase {
 
 		/**
 		 * Called when the initialization is completed.
-		 * 
+		 *
 		 * @see org.apache.uima.collection.processing.StatusCallbackListener#initializationComplete()
 		 */
 		public void initializationComplete() {
@@ -177,9 +141,9 @@ public class RegressionPipelineTest extends XMLTestCase {
 
 		/**
 		 * Called when the batchProcessing is completed.
-		 * 
+		 *
 		 * @see org.apache.uima.collection.processing.StatusCallbackListener#batchProcessComplete()
-		 * 
+		 *
 		 */
 		public void batchProcessComplete() {
 			logger.info("Completed " + entityCount + " documents");
@@ -188,7 +152,7 @@ public class RegressionPipelineTest extends XMLTestCase {
 
 		/**
 		 * Called when the collection processing is completed.
-		 * 
+		 *
 		 * @see org.apache.uima.collection.processing.StatusCallbackListener#collectionProcessComplete()
 		 */
 		public void collectionProcessComplete() {
@@ -206,7 +170,7 @@ public class RegressionPipelineTest extends XMLTestCase {
 
 		/**
 		 * Called when the CPM is paused.
-		 * 
+		 *
 		 * @see org.apache.uima.collection.processing.StatusCallbackListener#paused()
 		 */
 		public void paused() {
@@ -215,7 +179,7 @@ public class RegressionPipelineTest extends XMLTestCase {
 
 		/**
 		 * Called when the CPM is resumed after a pause.
-		 * 
+		 *
 		 * @see org.apache.uima.collection.processing.StatusCallbackListener#resumed()
 		 */
 		public void resumed() {
@@ -224,7 +188,7 @@ public class RegressionPipelineTest extends XMLTestCase {
 
 		/**
 		 * Called when the CPM is stopped abruptly due to errors.
-		 * 
+		 *
 		 * @see org.apache.uima.collection.processing.StatusCallbackListener#aborted()
 		 */
 		public void aborted() {
@@ -234,7 +198,7 @@ public class RegressionPipelineTest extends XMLTestCase {
 		/**
 		 * Called when the processing of a Document is completed. <br>
 		 * The process status can be looked at and corresponding actions taken.
-		 * 
+		 *
 		 * @param aCas
 		 *            CAS corresponding to the completed processing
 		 * @param aStatus
@@ -252,4 +216,4 @@ public class RegressionPipelineTest extends XMLTestCase {
 			entityCount++;
 		}
 	}
-}
+}
\ No newline at end of file
diff --git pom.xml pom.xml
index c8160b1d..09e22595 100644
--- pom.xml
+++ pom.xml
@@ -79,6 +79,7 @@
 		<ctakes.version>4.0.1-SNAPSHOT</ctakes.version>
 		<maven.compiler.source>1.8</maven.compiler.source>
 		<maven.compiler.target>1.8</maven.compiler.target>
+		<maven-surefire-plugin.version>2.12.1</maven-surefire-plugin.version>
 		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
 	</properties>
 
@@ -805,7 +806,7 @@
 					explicitly include files ending in "Tests" -->
 				<plugin>
 					<artifactId>maven-surefire-plugin</artifactId>
-					<version>2.12.1</version>
+					<version>${maven-surefire-plugin.version}</version>
 					<configuration>
 						<includes>
 							<include>**/Test*.java</include>
@@ -940,5 +941,25 @@
 				<additionalparam>-Xdoclint:none</additionalparam>
 			</properties>
 		</profile>
+		<!--  START SNIPPET: release-profile -->
+		<!-- !IMPORTANT: Overrides the official org.apache:apache (parent pom) -->
+		<profile>
+			<id>apache-release</id>
+            <build>
+				<plugins>
+					<plugin>
+						<groupId>org.apache.maven.plugins</groupId>
+						<artifactId>maven-surefire-plugin</artifactId>
+						<version>${maven-surefire-plugin.version}</version>
+						<configuration>
+							<environmentVariables>
+								<ctakes.umlsuser>CHANGE_ME</ctakes.umlsuser>
+							</environmentVariables>
+						</configuration>
+					</plugin>
+				</plugins>
+			</build>
+		</profile>
+		<!--  END SNIPPET: release-profile  -->
 	</profiles>
 </project>

Reply via email to