fix bugs and add more failure infos in pig native test code
fix bugs in platform implementations