mikelangelo-project / capstan

Capstan, a tool for packaging and running your application on OSv.
http://osv.io/capstan/
Other
19 stars 7 forks source link

Let ListImages() return a string instead printing to stdout #58

Closed miha-plesko closed 6 years ago

miha-plesko commented 6 years ago

With this commit we modify ListImages so that it now returns a string, which opens an opportunity to provide unit tests for it. We grab the opportunity and actually provide the unit tests. Having tests in place, we're confident enough to refactor the body of ListImages method that was implemented in a strange way and thus hardly understandable.

Depends on https://github.com/mikelangelo-project/capstan/pull/56

gberginc commented 6 years ago

@miha-plesko please rebase with #56.

miha-plesko commented 6 years ago

Rebased, repushed, green.

miha-plesko commented 6 years ago

I feel you - I had to test myself again if it works prior opening the PR, since I've implemented it long time ago and looking at the diff I was like "whuuuuuuuuut?!?!" 😄

I've added the comment that you asked for, please see.