fixed function count test for older Perl versions
added travis support