Replace raw match with match_houid in a spec

This commit is contained in:
Eric Schultz 2021-03-30 15:35:16 -05:00 committed by Eric Schultz
parent e26581dba5
commit 83e7c33e45

View file

@ -19,7 +19,7 @@ RSpec.describe SupporterNote, type: :model do
expect(Houdini.event_publisher).to receive(:announce).with(:supporter_created, anything)
expect(Houdini.event_publisher).to receive(:announce).with(:supporter_address_created, anything)
expect(Houdini.event_publisher).to receive(:announce).with(:supporter_note_created, {
'id' => match(/objevt_[a-zA-Z0-9]{22}/),
'id' => match_houid('objevt'),
'object' => 'object_event',
'type' => 'supporter_note.created',
'data' => {
@ -50,7 +50,7 @@ RSpec.describe SupporterNote, type: :model do
expect(Houdini.event_publisher).to receive(:announce).with(:supporter_address_created, anything)
expect(Houdini.event_publisher).to receive(:announce).with(:supporter_note_created, anything).ordered
expect(Houdini.event_publisher).to receive(:announce).with(:supporter_note_updated, {
'id' => match(/objevt_[a-zA-Z0-9]{22}/),
'id' => match_houid('objevt'),
'object' => 'object_event',
'type' => 'supporter_note.updated',
'data' => {
@ -83,7 +83,7 @@ RSpec.describe SupporterNote, type: :model do
expect(Houdini.event_publisher).to receive(:announce).with(:supporter_address_created, anything)
expect(Houdini.event_publisher).to receive(:announce).with(:supporter_note_created, anything).ordered
expect(Houdini.event_publisher).to receive(:announce).with(:supporter_note_deleted, {
'id' => match(/objevt_[a-zA-Z0-9]{22}/),
'id' => match_houid('objevt'),
'object' => 'object_event',
'type' => 'supporter_note.deleted',
'data' => {