Matthew Lindfield Seager

Matthew Lindfield Seager

I was curious how class​ Test < ActiveRecord::Migration[6.0] actually works under the covers. Three key discoveries were:

  • ActiveRecord::Migration[6.0] gets evaluated
  • Migration has a class method [](version)
  • Ruby has syntactic sugar where a[b] is the same as a.[](b)