Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Ruby

What can I be doing better?

I've been working on building my own rails app from scratch(not using scaffolding) and I'm looking for some feedback on the code. It is not complete yet, but I'm wanting to make sure I'm not doing anything ill advised for Rails.

The repo is https://github.com/simshawj/CosplayCompanionWebsite

Any feedback that can be given would be appreciated, whether it be the models, controllers, views, etc.

I am trying to do this with mostly TDD, though it does feel like I'm spending more time with the tests than I am with features.

Aaron Kaye
Aaron Kaye
10,948 Points

You may have provided the wrong link as you are in the Ruby forum and posted a link to an Android Repository. Looking at your public repositories I did see this:

https://github.com/simshawj/CosplayCompanionWebsite

Is that one correct?

Yes, serves me right for splitting the project like that. Fixing it in the main post now.

I'll also be a bit more specific in some of what I'm looking for.

My specs and factories seem to be a bit out of control so I wonder if I'm hitting just enough, too much, or too little with them or if there's much for refactoring and cleaning up that could get done(I would like to get them to be a bit more maintainable if possible). This is my first project that I've done with TDD so for all I know this could just be the nature of the beast and it will work itself out over time, but something has just been feeling wrong with it.

With my Factories, the whole association thing feels like I'm doing it wrong, but reading through the docs, I couldn't find any solutions that would be much more elegant than what I currently have.