tests: modified to be command line executed

Needing a custom html to run the test was really unconvenient. It
was replaced to be run using a javascript shell on a terminal. It
needs some custom built-in methods, so right now it would only work
if you use spider monkey.