Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 4568536
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T19:05:25+00:00 2026-05-21T19:05:25+00:00

How do you debug factory_girl? i’ve tried to put debugger in there but i

  • 0

How do you debug factory_girl? i’ve tried to put debugger in there but i just cant. I just want to test why my associations aren’t working right

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-21T19:05:26+00:00Added an answer on May 21, 2026 at 7:05 pm

    How did you use the debugger? If you tried to use it in test environment, I’m not surprised it didn’t work. But factory_girl is not limited to test environment.

    Simply require factory_girl gem and relevant factories in development environment, start the server with debugger (or just console) and you’re set for debugging.

    UPDATE

    I have this setup in https://github.com/lstejskal/icanhazblog. When you install it and run ‘rails console’, you can then do stuff like:

    $ a = Factory.create :article
    => #<Article _id: 4dc27b867319e80fb2000001, created_at: 2011-05-05 10:27:18 UTC,
    updated_at: 2011-05-05 10:27:18 UTC, title: "Article 1", content: "This is a content
    for Article 1.", visible: true, published_at: 2011-02-11 23:00:00 UTC, tags: ["ruby",
    "rails", "sinatra"]> 
    $ a.title
    => "Article 1" 
    

    Just add something like this when starting in development mode:

    require 'factory_girl'
    # require factories
    Dir["#{PATH_TO_FACTORIES}/*.rb"].each { |f| require f }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using FactoryGirl successfully, but I've just tried requiring the factory_girl/step_definitions file and am
I've tried calling both logger.debug and Rails.logger.debug but nothing is getting outputted to the
To debug some JavaScript code, I am looking for JavaScript code (preferably just js,
For debug use I want to show the type of a variable in Google
Debug HTTP is easy, you have all sort of tools to do it (like
Debug mode in MigLayout is quite powerful option for development and debugging. It is
Debug.WriteLine(Timer is high-resolution: {0}, Stopwatch.IsHighResolution); Debug.WriteLine(Timer frequency: {0}, Stopwatch.Frequency); Result: Timer is high-resolution: True
The debug configuration of my app is built against: PYTHON25_D.DLL MSVCR80D.DLL We use Python
To debug multithreaded programs to in case of conditions such as deadlock or livelock,
Ruby-debug is getting hung up by breaking on the break ruby reserved word on

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.