add javascript test and make check target

now it's possible to run javascript tests from the console:

    make testjs

While I was here I added the make check target to launch all tests.