Skip to content

Instantly share code, notes, and snippets.

View ashmaroli's full-sized avatar

Ashwin Maroli ashmaroli

View GitHub Profile
# frozen_string_literal: true
require 'memory_profiler'
def assert_equal(a, b)
puts "#{a} != #{b} at #{caller.last}" if a != b
end
def assert(allocated_memsize: nil, allocated_objects: nil)
report = MemoryProfiler.report { yield }