Fix rubocop nits

This commit is contained in:
Andreas Nedbal 2023-10-26 06:05:14 +02:00 committed by Andreas Nedbal
parent 1e29d3f86f
commit 20cf1ac85b
3 changed files with 6 additions and 4 deletions

View File

@ -1,6 +1,8 @@
# frozen_string_literal: true
class RenameAppendableToReaction < ActiveRecord::Migration[7.0] class RenameAppendableToReaction < ActiveRecord::Migration[7.0]
def change def change
rename_table :appendables, :reactions rename_table :appendables, :reactions
remove_column :reactions, :type remove_column :reactions, :type, :string
end end
end end

View File

@ -7,8 +7,8 @@ module UseCase
"reactions.json" => json_file!( "reactions.json" => json_file!(
reactions: [ reactions: [
*user.smiles.map(&method(:collect_reaction)) *user.smiles.map(&method(:collect_reaction))
] ],
) ),
} }
def collect_reaction(reaction) def collect_reaction(reaction)

View File

@ -9,7 +9,7 @@ describe UseCase::DataExport::Reactions, :data_export do
it "returns an empty set of reactions" do it "returns an empty set of reactions" do
expect(json_file("reactions.json")).to eq( expect(json_file("reactions.json")).to eq(
{ {
reactions: [] reactions: [],
} }
) )
end end