about summary refs log tree commit diff
path: root/spec
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2019-07-28 17:47:37 +0200
committerGitHub <noreply@github.com>2019-07-28 17:47:37 +0200
commitb9b0313c78ca4efcc8cda089c652be0b333aa16a (patch)
tree7f94dada733b514a2034839c3ca6fb6776487250 /spec
parent75f7f9930eb2a6f5c4041ec44fe0aa795c9ec449 (diff)
Revert "Remove conversation URI (#11423)" (#11424)
This reverts commit 75f7f9930eb2a6f5c4041ec44fe0aa795c9ec449.
Diffstat (limited to 'spec')
-rw-r--r--spec/models/conversation_spec.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/spec/models/conversation_spec.rb b/spec/models/conversation_spec.rb
index b91d36169..8b5e4fdaf 100644
--- a/spec/models/conversation_spec.rb
+++ b/spec/models/conversation_spec.rb
@@ -1,5 +1,13 @@
 require 'rails_helper'
 
 RSpec.describe Conversation, type: :model do
+  describe '#local?' do
+    it 'returns true when URI is nil' do
+      expect(Fabricate(:conversation).local?).to be true
+    end
 
+    it 'returns false when URI is not nil' do
+      expect(Fabricate(:conversation, uri: 'abc').local?).to be false
+    end
+  end
 end