add skeleton test case for node type
moving getc() into the while loop introduced a bug on digits.
improve node_test, handle NULL on node_new(..., NODE_FUNC, ...)