perl distributive "early" testing with jenkins
Often when deploying application one may face the risk of divergence between testing and production environment. Even though you have a stage servers `like production one', it'd be reasonable to check distributive in production environment before release is happened. I would call it `early` testing. Yes, of course, some subtle bugs will arise only in runtime phase, and unit test cannot cover it all, I say here about prerequisite unmet issues. In perl world unit tests and prerequisites checks are executed in standart way. One follows standard procedure, when installing things.
I put here example for Module::Build based project, but with ExtUtils::MakeMaker it's almost the same:
perl Build.PL # check dependencies and generate build file ./Build ./Build test # run unit tests
So, why not to automate this process in continues integration approach, like for example Jenkins does?
- Upload distributive to production server
- Unpack it
- Run standard perl Build.PL/Makefile.PL cycle to execute unit tests and check prerequisites
- If anything goes wrong you know it in good time, before release is happened!
So this is what I've done in jenkins perl-smoke-test plugin. Please check it out and try to use it!Links:
- plugin home page - https://github.com/melezhik/perl-smoke-test-plugin
- download plugin here - http://repo.jenkins-ci.org/snapshots/org/jenkins-ci/ruby-plugins/perl-smoke-test/