Bug fixes and methods renamed to .has() and .belongsTo().

Integration test created to check new functionality.