Skip to content

Commit

Permalink
Refactor into 1 line
Browse files Browse the repository at this point in the history
  • Loading branch information
ur5us committed Oct 28, 2023
1 parent c78b8c5 commit 097c6d1
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions test/test_activity.rb
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@

describe '#render' do
subject do
s = PublicActivity::Activity.new(key: 'activity.test', parameters: { one: 1 })
s.save && s
PublicActivity::Activity.new(key: 'activity.test', parameters: { one: 1 }).tap(&:save)
end

let(:template_output) { "<strong>1, 2</strong>\n<em>activity.test, #{subject.id}</em>\n" }
Expand Down

0 comments on commit 097c6d1

Please sign in to comment.