Not necessary at all, I just wanted to get test in fast and didn't want to copy-paste int main() to my test code, like most of the other regression tests seems to be doing. 

Actually I would like more to have cmd program which runs kernels with some arguments and provides way to verify results. Something like this, but less brutally coded:  https://github.com/KhronosGroup/webcl-validator/blob/master/test/kernel-runner/main.cpp

Then one may just call: run-kernel test_code.cl --kernel test_kernel --global float 128 --global float 128 --globalsize 128 | grep "Expected result"