mirror of
https://github.com/Freika/dawarich.git
synced 2026-01-10 01:01:39 -05:00
18 lines
371 B
Ruby
18 lines
371 B
Ruby
# frozen_string_literal: true
|
|
|
|
require 'rails_helper'
|
|
|
|
RSpec.describe NotificationsChannel, type: :channel do
|
|
let(:user) { create(:user) }
|
|
|
|
before do
|
|
stub_connection(current_user: user)
|
|
end
|
|
|
|
it 'subscribes to a stream for the current user' do
|
|
subscribe
|
|
|
|
expect(subscription).to be_confirmed
|
|
expect(subscription).to have_stream_for(user)
|
|
end
|
|
end
|