diff options
author | Claire <claire.github-309c@sitedethib.com> | 2023-03-16 23:09:53 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-03-16 23:09:53 +0100 |
commit | f5daa20f2a90098c9d689c5ec9d95ce9887b3a33 (patch) | |
tree | a225407cb43edf3fa9d9ac0100021a380e11ff91 /spec/serializers/activitypub/undo_like_serializer_spec.rb | |
parent | 6a0ed45aa3f11f0343a7be556b36b4d075ba08df (diff) | |
parent | 32418f0ff3e7f25ca67334585d6d8442b34cb4af (diff) |
Merge pull request #2134 from ClearlyClaire/glitch-soc/merge-upstream
Merge upstream changes
Diffstat (limited to 'spec/serializers/activitypub/undo_like_serializer_spec.rb')
-rw-r--r-- | spec/serializers/activitypub/undo_like_serializer_spec.rb | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/spec/serializers/activitypub/undo_like_serializer_spec.rb b/spec/serializers/activitypub/undo_like_serializer_spec.rb new file mode 100644 index 000000000..43cf7192e --- /dev/null +++ b/spec/serializers/activitypub/undo_like_serializer_spec.rb @@ -0,0 +1,20 @@ +# frozen_string_literal: true + +require 'rails_helper' + +describe ActivityPub::UndoLikeSerializer do + let(:serialization) do + JSON.parse( + ActiveModelSerializers::SerializableResource.new( + record, serializer: described_class + ).to_json + ) + end + let(:record) { Fabricate(:favourite) } + + describe 'type' do + it 'returns correct serialized type' do + expect(serialization['type']).to eq('Undo') + end + end +end |