Skip to content
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

Unit testing #51

Open
dimon222 opened this issue May 22, 2017 · 3 comments
Open

Unit testing #51

dimon222 opened this issue May 22, 2017 · 3 comments
Assignees

Comments

@dimon222
Copy link
Member

dimon222 commented May 22, 2017

I know I have done some pull requests that at some point were breaking script on several VPS configs.
It would be good to have some Unit testing for current script, so it can be prevented in the future (or at least warned before it gets merged by accident).

So far it doesn't seem to be trivial at all, since we basically have one big bash script. I quite expect this issue to be opened for a while.

There are multiple things to be tested like regression test of performance, functionality on special cases (missing installs for some apps), text offsets and other things.

I do really like this Bats option. Not sure yet how we can implement it. Its quite possible that some reorganization of script will be required like more atomic functions.

@willemdh
Copy link
Member

Definitely sounds like a good idea. Imho the difficulty will be the wide array of os'es FireMotD supports. What exactly do you mean with 'more atomic functions'?

@dimon222
Copy link
Member Author

Bats is mainly used for one-liner tests.
I'm not quite sure if there's any other approach other than having big amount of functions, which at this moment FireMotD doesn't really have.

@willemdh
Copy link
Member

willemdh commented Oct 7, 2017

I'm going to assign this to you @dimon222
As I never used Bats

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

2 participants