1 # frozen_string_literal: true
6 class DiaryCommentViewTest < ActionView::TestCase
8 diary_comment = build_stubbed(:diary_comment)
9 notification = build_stubbed(:notification, :record => diary_comment)
10 notification_wrapper = UserNotifications::DiaryCommentNotification.new(notification)
12 render "notifications/diary_comment", :notification => notification_wrapper
14 assert_dom ".user-notification h2", "Diary comment"
15 assert_dom ".user-notification time", "less than 1 minute ago"
16 assert_dom ".user-notification blockquote", diary_comment.body