You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi @mcmire,
thank you a lot for an amazing gem! It removed a lot of pain from working with some of the specs we have in the codebase.
I noticed that after upgrading super_diff to 0.8 our test suite slowed down by 4x (from ≈30s to 2m). Downgrading to 0.7 resolves the issue.
I ran some profiling and tried to analyse execution path, and it looks like the issue appeared after merging #91. Profiling showed that majority of the time is spent in SuperDiff::ObjectInspection::InspectionTree#render_to_string.
I tried to understand what's going on and how it would be possible to avoid that, but wasn't able to, unfortunately.
Attaching the profiling screenshot:
The text was updated successfully, but these errors were encountered:
Sorry for taking so long to reply to this issue. It initially surprised me to hear that the gem decreased performance because it really should only kick in when a test fails, but after looking at your screenshot, I'm realizing that the gem monkeypatches the description for each built-in RSpec matcher, so every time RSpec accesses a description it'll go through some logic here in the gem. I would imagine that some simple tricks can be applied to the inspection logic to fix the performance issue. Anyway, thank you for reporting this. I admit that I've been lax in tending to this gem lately due to life, but I will try to make an effort to take a closer look at this soon.
Hi @mcmire,
thank you a lot for an amazing gem! It removed a lot of pain from working with some of the specs we have in the codebase.
I noticed that after upgrading
super_diff
to 0.8 our test suite slowed down by 4x (from ≈30s to 2m). Downgrading to 0.7 resolves the issue.I ran some profiling and tried to analyse execution path, and it looks like the issue appeared after merging #91. Profiling showed that majority of the time is spent in
SuperDiff::ObjectInspection::InspectionTree#render_to_string
.I tried to understand what's going on and how it would be possible to avoid that, but wasn't able to, unfortunately.
Attaching the profiling screenshot:
The text was updated successfully, but these errors were encountered: