Add tests and simplify Stat function

Conflicts:
	src/node_file.cc
	test/simple/test-fs-stat.js