Closed swills closed 8 years ago
I think this is looking good!
There was a bug in recent versions of vagrant that prevented running the test suite, but it's been fixed in 1.8.5.
Once you have added tests, just push them to your byhve branch so that they're added to this PR.
Tests added.
Had to modify the existing tests to pass on my system. There were basically two changes to the tests themselves, one is simply changing the path. I'm not sure how we can modify them so that they work on every system. Another was changing the contents of the expected images, which I think is due to a difference in version of qemu that I'm using. I've made a gist of the diff of the hexdumps of them here:
https://gist.github.com/swills/135e758ca6a56478d84b665fa2c1442d
(I don't think it's due to the change in the compat flag being only passed in the qcow2 case. I tested without that change and still had these changes)
There was also a change to the test code to help it find binaries on my system.
Hope everything looks OK to you.
I plan to make more changes so that different loaders in metadata.json work properly (used for different OSs in bhyve), but I think the tests are going to have to modified to test multiple different inputs for each provider in that case.
Comments addressed.
Though at this point it's a lot of commits (including me merging the nokogiri branch in there at some point just so I could test a bit and then reverting it). I could squash some of the commits if you want, but it might be a bit of a pain.
Thanks!
This commit adds initial support for the bhyve box format from vagrant-bhyve. Note that there's more to do such as supporting different loaders. I want to go ahead and see what you think of this before going too far.
Also there's a change in here to make vagrant-mutate only pass the compat option to the qemu-img command if the format for output is qcow2 as passing it with other formats produces an error.
As noted in previous issue, I haven't been able to run the test suite, though I have tried. Once I manage to do that I'll add tests for these changes.