From 3cd7f6915d43f927256fb2c91f65e80663a95296 Mon Sep 17 00:00:00 2001 From: Pat Allan Date: Thu, 22 Jun 2017 14:52:53 +1000 Subject: [PATCH] Allow library to be used with frozen-string-literals enabled. For the tests to pass, this requires the use of the latest RSpec commits, along with submitted patches to simplecov-html and test-unit: * https://github.com/colszowka/simplecov-html/pull/56 * https://github.com/test-unit/test-unit/pull/149 --- lib/simplecov/formatter/simple_formatter.rb | 2 +- lib/simplecov/version.rb | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/simplecov/formatter/simple_formatter.rb b/lib/simplecov/formatter/simple_formatter.rb index cc7fa9a9..a90e7859 100644 --- a/lib/simplecov/formatter/simple_formatter.rb +++ b/lib/simplecov/formatter/simple_formatter.rb @@ -6,7 +6,7 @@ module Formatter class SimpleFormatter # Takes a SimpleCov::Result and generates a string out of it def format(result) - output = "" + output = "".dup result.groups.each do |name, files| output << "Group: #{name}\n" output << "=" * 40 diff --git a/lib/simplecov/version.rb b/lib/simplecov/version.rb index 443eb9d4..bac1ee82 100644 --- a/lib/simplecov/version.rb +++ b/lib/simplecov/version.rb @@ -1,5 +1,5 @@ module SimpleCov - version = "0.14.1" + version = "0.14.1".dup def version.to_a split(".").map(&:to_i)