Add scalar type metadata refinement for JSON profiles

You are only testing longs. Add tests to ensure that doubles, strings and booleans are also treated correctly.