From 4fae905655a9f51bf3f9041a5e30eb0bcec327d3 Mon Sep 17 00:00:00 2001 From: Daniel O'Connor Date: Sat, 13 Jul 2024 08:55:11 +0000 Subject: [PATCH] Style/StringConcatenation --- .rubocop_todo.yml | 7 ------- test/acts_as_commentable_test.rb | 10 +++++----- 2 files changed, 5 insertions(+), 12 deletions(-) diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml index ac7fd0d..81d4f3b 100644 --- a/.rubocop_todo.yml +++ b/.rubocop_todo.yml @@ -102,10 +102,3 @@ Style/FrozenStringLiteralComment: - 'test/acts_as_commentable_test.rb' - 'test/models.rb' - 'test/schema.rb' - -# Offense count: 5 -# This cop supports unsafe autocorrection (--autocorrect-all). -# Configuration parameters: Mode. -Style/StringConcatenation: - Exclude: - - 'test/acts_as_commentable_test.rb' diff --git a/test/acts_as_commentable_test.rb b/test/acts_as_commentable_test.rb index e471657..36555aa 100644 --- a/test/acts_as_commentable_test.rb +++ b/test/acts_as_commentable_test.rb @@ -1,21 +1,21 @@ require 'test/unit' require 'logger' require 'pry' -require File.expand_path(File.dirname(__FILE__) + '/../rails/init') +require File.expand_path("#{File.dirname(__FILE__)}/../rails/init") ActiveRecord::Migration.verbose = false ActiveRecord::Base.establish_connection(adapter: 'sqlite3', database: ':memory:') class ActsAsCommentableTest < Test::Unit::TestCase def setup_comments - require File.expand_path(File.dirname(__FILE__) + '/../lib/generators/comment/templates/create_comments') + require File.expand_path("#{File.dirname(__FILE__)}/../lib/generators/comment/templates/create_comments") CreateComments.up - load(File.expand_path(File.dirname(__FILE__) + '/../lib/generators/comment/templates/comment.rb')) + load(File.expand_path("#{File.dirname(__FILE__)}/../lib/generators/comment/templates/comment.rb")) end def setup_test_models - load(File.expand_path(File.dirname(__FILE__) + '/schema.rb')) - load(File.expand_path(File.dirname(__FILE__) + '/models.rb')) + load(File.expand_path("#{File.dirname(__FILE__)}/schema.rb")) + load(File.expand_path("#{File.dirname(__FILE__)}/models.rb")) end def setup