Skip to content
Menu
Justin Ball
  • About
  • Privacy Policy
Justin Ball

Category: tests

undefined method `assert_no_difference’ and `assert_difference’

Posted on January 1, 2010November 1, 2021

I’ve been upgrading some old code and noticed that my unit tests started spitting out a lot of errors like this: undefined method `assert_no_difference’ </pre> and undefined method `assert_difference’ </pre> It turns out that I needed to change my base classes from Test::Unit::TestCase to ActiveSupport::TestCase: class UserTest < Test::Unit::TestCase # stuff end </pre> changes to:…

©2025 Justin Ball | Powered by SuperbThemes & WordPress