-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Running the integration tests does not work as described #205
Comments
Notes on the test failures: the cause of the error in the test results was that one test tried to login as user For the first failing test, I found the cause and suggest a fix in #206. The second test failure is dubious. The test |
I believe that the majority of the issues raised in this issue have been solved. I updated the icat.server wiki with instructions that work based on our Vagrant installation tutorial, of which the main points are below:
In addition to this, the integration tests are now being ran successfully on TravisCI, which provides an actual example of how to set up the environment to run the tests, using the Another issue I fixed was that the tests were not correctly setting up data before running and clearing data after running, which caused problems in that tests depended on other tests being ran first. To fix this, I added The only leftover point that I can see is that we rely on the JDBC connection pool left behind by a previous installation of |
I acknowledge big progress has been made on this. I still see two issues though:
I'd suggest to do the following (similar to ids.server) to solve both at the same time:
|
I just tried to run the integration tests. My experiences so far:
First try. I followed the instructions from the icat.server wiki. I set up a test server having
authn.db-2.0.0
,icat.lucene-1.1.0
, andicat.server-4.9.1
deployed. I tried to runmvn install
in the current source tree. After compile, the deploying oficat.server-4.9.2-SNAPSHOT.war
failed with anInitialization failed for Singleton PropertyHandler
exception caused byjava.lang.IllegalStateException: class org.icatproject.core.IcatException No authenticator of type db is working
.Investigating the issue, it looks like the settings from src/main/resources/run.properties are hard coded to be used in the integration tests. It is pretty obvious that
authn.db
cannot be reached by the URLhttps://smfisher:8181
in my environment. As opposed to what is stated in the instructions in the wiki, theserverUrl
in~/.m2/settings.xml
seem to be ignored.Second try. I edited
src/main/resources/run.properties
to hard code settings that would work in my environment. This time, deploying oficat.server-4.9.2-SNAPSHOT.war
failed because theserver already has a web module icat.server-4.9.1 loaded at /icat
. So the force-deploying was not able to overwrite the already installed oldericat.server
.Third try. I uninstalled
icat.server-4.9.1
and tried again. Now, the deploying failed with ajava.lang.RuntimeException: Invalid resource : jdbc/icat__pm
. Apparently, the integration test did not try to create the JDBC connection pool to connect to the database. In fact, I did not found any configuration settings in the sources that one useually would put into thesetup.properties
to point to the database.Fourth try. I reinstalled
icat.server-4.9.1
and then undeployed it manually. This created the JDBC connection pool as a side effect and left it behind, because I didn't use the setup script to uninstall. Now this did the trick. I got two failures, one errors, and three skipped out of 66 tests, but this is another issue to be investigated separately. But at least the test suite did run at all.Unless I am overlooking something fundamental, this current state is not suitable to encourage anybody to run the tests.
The text was updated successfully, but these errors were encountered: