hi
i have a non active_record class in models dir which is like following:
class BuildSurvey
end
i want to test this class,so manually defined a test file which is like
following
require 'test_helper'
require 'build_survey'
class BuildSurveyTest < ActiveSupport::TestCase
end
but when i ran test,i got error like this:
undefined method '<' nil:NilClass
i want to know how to test a non active_record class in models directory
in rails 3.can you help me?
You don't have to do anything beyond what you've shown (the require
build_survey is unnecessary)
You're going to have to show a little more (eg what does the
backtrace for that error look like?)