Skip to content

Commit 1599e87

Browse files
Watson1978kou
authored andcommitted
test: add a performance test for PI with many tabs
1 parent e2546e6 commit 1599e87

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

test/parse/test_processing_instruction.rb

+7
Original file line numberDiff line numberDiff line change
@@ -116,5 +116,12 @@ def test_linear_performance_gt
116116
REXML::Document.new("<?xml version=\"1.0\" " + ">" * n + " ?>")
117117
end
118118
end
119+
120+
def test_linear_performance_tab
121+
seq = [10000, 50000, 100000, 150000, 200000]
122+
assert_linear_performance(seq, rehearsal: 10) do |n|
123+
REXML::Document.new("<?name" + "\t" * n + "version=\"1.0\" > ?>")
124+
end
125+
end
119126
end
120127
end

0 commit comments

Comments
 (0)