Fix get_progname segfaults and added scripts/test.pl, scripts/test.json, and test.sh