-
Notifications
You must be signed in to change notification settings - Fork 492
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
improve ability of developers to run integration tests #4369
Comments
@pameyer thanks for pull request #4370 ! I'm copying and pasting a comment I just left there because we tend to favor discussion in issues rather than pull requests: @pameyer overall, this is a very interesting contribution. I was going to try to execute your code but I'm blocked on not knowing what "surgery" steps are necessary and am much more interested in a fully automated solution than one with manual steps. Both Vagrant and our existing Docker files set up Glassfish and Solr in an automated way. Can we do the same in this "all in one" solution? Also, there seems to be some duplication of files, such as the Solr schema.xml and the |
|
@pameyer talked this out a bit at http://irclog.iq.harvard.edu/dataverse/2017-12-12 and plan to meet up tomorrow if time allows. It would do me good to see a demo. |
I got a great brain dump from @pameyer as well as some "deps" (dependencies, two tarballs) I need to try to execute the code in his pull request. The Day of Meetings prevented us from talking more about running tests on developers' laptops vs. Jenkins but I have a much better understanding of where @pameyer is coming from and I like the way he thinks! |
@pameyer thanks for providing me with
Oh, also, your pull request includes a @donsizemore since the pull request uses CentOS 7 rather than CentOS 6, you might be interesting in taking a look as you poke at #4384. The last thing I'll say for now is that I still want to talk to @pameyer about how we can execute all this great code automatically from Jenkins or Travis or some other continuous integration service. This pull request does definitely add value in the sense that it forces the user to run the installer. This differs from the phoenix setup where I ran a shell script that was somewhat equivalent to the installer a couple years ago. Right now we already say "To run more than one test at a time, separate by commas" over at http://guides.dataverse.org/en/4.8.4/developers/testing.html#integration-tests but developers are not in the habit of running all the tests on their laptops. I think it's too much to ask. These tests should be run automatically on a server. I think this pull request is incremental progress toward that goal, something @bjonnh and I have talked about. Sorry so rambly. |
@pdurbin Longer term, I'd been thinking it would make sense to have a Jenkins declarative pipeline that would build everything (war, installer zip, docker images), run the unit and integration tests (and browser-based tests if/when they become available), and generate coverage reports (I'm pretty sure coveralls is missing integration test coverage). I'd missed that other copy of pg_hba.conf. It may be possible to extend Travis to build images / run integration tests, but it's an approach I'm less familiar with. |
I would be nice to know why |
Note to self: to get a shell in the Docker container: |
server.log is showing this which I believe is normal because it's what we're testing above:
|
I just ran the test suite for the second time and this time it worked (I'm not sure why):
|
@pameyer just had a very productive conversation lasting over an hour. I'm too lazy to type up a todo list but my chicken scratch will remind me: |
@pameyer it occurs to me that perhaps the subject of issue should include QA. Right now it sounds quite oriented toward developers. |
In bc7aa68 I explained in the Dev Guide that there are now two different uses of Docker once pull request #4370 is merged:
@pameyer hopefully it's clear enough from that commit where you can add additional documentation if you are so inclined. Here's the todo list @pameyer and I came up with yesterday:
The main goal of this current effort is to make it easier to run the full REST Assured API Test suite before merging a pull request. Obviously, not every pull request needs to have the full test suite run against it. Sometimes we only make minor documentation changes. The target environment for running the test suite is a Mac but in the future we can imagine further automation where Jenkins kicks off testing on a Linux box, probably in the cloud. We also talked about the value add that this effort represents. Here's my take on the value add, most value first:
Finally, in a way, this issue is the real #3938 in my mind. That is to say, it's focused much more on Docker alone without adding Minishift/OpenShift into the mix. @pameyer I'm taking myself off this issue since I made the tweaks to the documentation I wanted to. I'm happy to pitch in if you need any help with the todo list above. I also put a but in @bjonnh 's ear over at http://irclog.iq.harvard.edu/dataverse/2017-12-15#i_61497 . Good work. I like the direction this effort is taking. |
@pameyer did all the stuff we talked about (thanks!) so I moved this issue and pull request #4370 to QA. The starting point for testing is a line in the "Development Environment" section of the Dev Guide that says this:
That readme can be found here: https://github.com/IQSS/dataverse/tree/d0f4c68d2ad26928fd185018d91ecdeb70c91e9e/conf/docker-aio I just ran through all the step as of the commit above and got |
Just a heads up that in e796935 I'm fixing up the readme for the "all in one" Docker environment and explaining how it fits into our testing strategy. |
Integration tests at https://build.hmdc.harvard.edu:8443/job/phoenix.dataverse.org-apitest-develop/ are useful; documentation of how to run these tests on a local system can be confusing for a new developer.
possibly related: #3938, #1936, #3959 , #2443
The text was updated successfully, but these errors were encountered: