summaryrefslogtreecommitdiff
path: root/spec/models/note_spec.rb
diff options
context:
space:
mode:
authorValery Sizov <valery@gitlab.com>2015-12-11 13:10:00 +0200
committerValery Sizov <valery@gitlab.com>2015-12-11 13:17:12 +0200
commit72b7d1f59d4fb26fb9119c5a059528f0fc951904 (patch)
tree18faa50e9d67746be474577f395c720ff49df81b /spec/models/note_spec.rb
parentcd97dba2a9a26e83818f7e111bc0b0185a7ced8a (diff)
downloadgitlab-ce-72b7d1f59d4fb26fb9119c5a059528f0fc951904.tar.gz
emoji aliases problem
Diffstat (limited to 'spec/models/note_spec.rb')
-rw-r--r--spec/models/note_spec.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/spec/models/note_spec.rb b/spec/models/note_spec.rb
index 5b6f177ebb2..216c7dabae0 100644
--- a/spec/models/note_spec.rb
+++ b/spec/models/note_spec.rb
@@ -159,4 +159,13 @@ describe Note, models: true do
expect(note.editable?).to be_falsy
end
end
+
+ describe "set_award!" do
+ let(:issue) { create :issue }
+
+ it "converts aliases to actual name" do
+ note = create :note, note: ":thumbsup:", noteable: issue
+ expect(note.reload.note).to eq("+1")
+ end
+ end
end