Add some more tests to parser

This assertion is a bit problematic. The spec requires that the `type` be an instance of `Ref`, therefore a stricter assertion would be

    assert(isinstance(type, Ref))

Though this is is better, it is still not the appropriate test. Suppose we try to parse the following

    let mutable a : ref int

According to the spec, the `type` of `a` is `ref ref int`. Now suppose the parser has a bug and does not pack `ref int` appropriately and sets `type` to `ast.Ref(ast.Int())`. Then all assertions will pass, even though the parser failed to function correctly.

The correct way to test this is via unit testing: If the user supplies a type `T` to the definition, then the parser should set the `type` attribute to `ast.Ref(T)`, and similarly for other nodes (like `FunctionDef` and  `ArrayVariableDef`)

In addition, all these `type`s should be validated, but this should probably be left for the semantic analysis pass.