Why Shell Scripts #590
Replies: 8 comments 1 reply
-
For testing the bash scripts, take a look at https://github.com/hpi-swa/smalltalkCI/tree/master/tests . It's using shunit2 . |
Beta Was this translation helpful? Give feedback.
-
Thanks, that helps. I see shunit2 seems to have decent docs. Although, why not use something in Smalltalk like this rather than spend more time in the horrifying world of shell scripts: I hope it doesn't sound like I'm complaining. I'm just wondering if this has ever been considered and maybe even rejected for a good reason I'm not seeing... |
Beta Was this translation helpful? Give feedback.
-
SmalltalkCI tries to do as little as possible in Bash for bootstrapping, but that still is more than we like. We once considered moving more setup bits to Smalltalk, but that would've meant that you need to download another image and another VM, and that only makes the service slower and increases the potential for errors (e.g., bad internet connection). If you have any ideas how to improve the bootstrapping process, please let us know or open PRs. :) |
Beta Was this translation helpful? Give feedback.
-
Please have a look at this spike which allows unit testing shell scripts from within Smalltalk. That's how I tested the GToolkit platform support code. Let me know if you think it is worthwhile pursuing. |
Beta Was this translation helpful? Give feedback.
-
Testing Bash code in Smalltalk is of course an option, but may also be confusing and not easy to discover because you typically edit Bash and Smalltalk code in different IDEs (not sure you're editing Bash in GToolkit as well). I'd be inclined to keep it simple and just add some simple Bash tests for the GToolkit integration. |
Beta Was this translation helpful? Give feedback.
-
Thanks everyone for the dialogue. It was illuminating |
Beta Was this translation helpful? Give feedback.
-
As I flop around trying to learn Bash in order to add GToolkit as a supported platform, I am left wondering: why not have a thin layer of shell scripts in order to get a minimal Smalltalk image as soon as possible in which to continue the setup work as opposed to doing everything in shell scripts? Has this been contemplated? Worked on?
Also, how are all the shell scripts tested? I'd like to write tests for the GToolkit stuff but I'm not sure where to look. Upon further investigation, I see the tests folder. How does one run the tests locally? Is there documentation? Also, the prospect of having to understand this new ecosystem brings me back to my previous question: why not test in Smalltalk?
Beta Was this translation helpful? Give feedback.
All reactions