Association methods are now generated in modules

Mirrors
https://github.com/rails/rails/commit/7cba6a37848ba96b4decec885779fb309d71c339
and
https://github.com/rails/rails/commit/124c97fbe201f810d77f807ce69f37148e903c44