Added missing global functions

Beginning of some typescript tests to check typing are working.

Need to resolve issue with extensions of built in types from lib.d.ts
Array, Boolean, Number etc.