Fix for smart_associations

Fixes an issue with generating the names and determining the types of
fields on target models for hasOne associations.
Handle `id: [...]` correctly by transferring it to keys instead of just
blindly wrapping everything in an array.

Also increased the timeout for hasMany associations tests, since they seemed
to intermittently timeout.