Skip to content

Commit 02ce298

Browse files
keithrbennettjeremyevans
authored andcommitted
Add comment about terminating newline in captions; fix test method name.
1 parent 926c883 commit 02ce298

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

lib/benchmark.rb

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,9 @@ module Benchmark
128128
# benchmark tests. Reserves +label_width+ leading spaces for
129129
# labels on each line. Prints +caption+ at the top of the
130130
# report, and uses +format+ to format each line.
131+
# (Note: +caption+ must contain a terminating newline character,
132+
# see the default Benchmark::Tms::CAPTION for an example.)
133+
#
131134
# Returns an array of Benchmark::Tms objects.
132135
#
133136
# If the block returns an array of

test/benchmark/test_benchmark.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ def test_benchmark_does_not_print_any_space_if_the_given_caption_is_empty
7171
BENCH
7272
end
7373

74-
def test_benchmark_makes_extra_calcultations_with_an_Array_at_the_end_of_the_benchmark_and_show_the_result
74+
def test_benchmark_makes_extra_calculations_with_an_Array_at_the_end_of_the_benchmark_and_show_the_result
7575
assert_equal(BENCHMARK_OUTPUT_WITH_TOTAL_AVG,
7676
capture_bench_output(:benchmark,
7777
Benchmark::CAPTION, 7,

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy