[ci skip] Fix number of methods added by association.

Also clean up some trailing spaces on line 1143-1146.
Merge pull request #12564 from JuanitoFatas/association-basics

[ci skip] Fix number of methods added by association.