Skip to content

Commit ea32952

Browse files
committed
Fix allocation counts in rendering_test
1 parent 1661228 commit ea32952

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

test/sandbox/test/rendering_test.rb

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,14 @@ def test_render_inline_allocations
1616
MyComponent.ensure_compiled
1717

1818
allocations =
19-
if Rails.version.to_f < 8.0
19+
if Rails.version.split(".").first(2).map(&:to_i) == [7, 1] && ViewComponent::Base.config.capture_compatibility_patch_enabled
20+
{"3.2.9" => 128}
21+
elsif Rails.version.to_f < 8.0
2022
{"3.3.10" => 126, "3.2.9" => 129, "3.1.7" => 130, "3.0.7" => 131}
2123
elsif Rails.version.split(".").first(2).map(&:to_i) == [8, 0]
2224
{"3.5.0" => 118, "3.4.7" => 122, "3.3.10" => 134}
2325
else
24-
{"3.4.7" => 120}
26+
{"3.5.0" => 116, "3.4.7" => 120}
2527
end
2628

2729
assert_allocations(**allocations) do

0 commit comments

Comments
 (0)