verivital / hyst

HyST: A Source Transformation and Translation Tool for Hybrid Automaton Models
http://verivital.com/hyst/
Other
15 stars 18 forks source link

WIP: Docker container, Continuous Integration #42

Closed MaxGaukler closed 5 years ago

MaxGaukler commented 5 years ago

First of all, thanks for providing this great tool!

I tried to set up a reproducible build and test environment because the REVM is rather old and I couldn't find out how to build a new one without lots of manual work and "reverse engineering" the old REVM.

The result is a Docker container which is also usable for travis-ci.org, a web service which automatically checks if all tests pass in your code. (Example: https://travis-ci.org/MaxGaukler/hyst/branches ) Docker has the benefit that all containers are volatile and therefore it's always reproducible how they were built. The main downsides are that you can't use it for GUI (except if you use some strange hacks), and you have to explicitly specify "shared folders" like in a VM. However, the Dockerfile is also a good and automatically tested (!) documentation on how to build the tool manually.

Some bugs showed up while developing this, I will report these separately.

This pull request is not supposed to be ready for merging, but rather a first draft as request for comments. For example, I don't like including the SpaceEx binary in the Git repository, but it seems there is no URL suitable for automatic downloads.

stanleybak commented 5 years ago

Great, thank you for doing this; I'll look through it. Yes I'm not sure how to solve the tool issue, short of not including those tools in the tests (but then thing might mean things break as tool syntax changes, such as what happened for Flow*).

MaxGaukler commented 5 years ago

I sent an email to the SpaceEx authors, I hope they can help.

If not, one workaround would be providing the tool binaries in a separate repository (or on some web server), at least for the tools where the license allows that. Then we don't pollute the main repository, but still have a download link. For software with restrictive licensing such as Matlab or C2E2 there will probably never be a (legal) way to do it.

MaxGaukler commented 5 years ago

Thanks for merging. You should now be able to enable Travis CI for the repository, so that every pull request and commit receives a little green checkmark to show that the unittests succeeded (or a big warning if not).

According to their help, you (or maybe the repository owner) need to do this:

Go to Travis-ci.org and Sign up with GitHub. Accept the Authorization of Travis CI. You’ll be redirected to GitHub. Click the green Activate button, and select the repositories you want to use with Travis CI. (probably on https://travis-ci.org/account/repositories )

stanleybak commented 5 years ago

Taylor,

With Max's help Hyst now has a continuous integration setup using docker that automatically installs the tools, sets up the environments, and runs all the tests. You need to enable this in Travis-ci.org though (see instructions below), which is associated with github. There's a little logo in the README that will tell you if all the tests are passing and provide a link to the terminal output.

-Stan

On Tue, Jan 29, 2019 at 11:14 AM MaxGaukler notifications@github.com wrote:

Thanks for merging. You should now be able to enable Travis CI for the repository, so that every pull request and commit receives a little green checkmark to show that the unittests succeeded (or a big warning if not).

According to their help, you (or maybe the repository owner) need to do this:

Go to Travis-ci.org and Sign up with GitHub. Accept the Authorization of Travis CI. You’ll be redirected to GitHub. Click the green Activate button, and select the repositories you want to use with Travis CI. (probably on https://travis-ci.org/account/repositories )

— You are receiving this because you modified the open/close state. Reply to this email directly, view it on GitHub https://github.com/verivital/hyst/pull/42#issuecomment-458601876, or mute the thread https://github.com/notifications/unsubscribe-auth/AKE7KfpPht8szB7dBdSLGlB09O8b7Acmks5vIHNsgaJpZM4Z-dSa .

ttj commented 4 years ago

Ok, thanks, sorry I missed this as well, I think I have enabled it and think I've gotten it started running:

https://travis-ci.com/github/verivital/hyst/builds/154621891