Permette di scegliere 12 ore, 24 ore o la settimana nello storico invii.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -36,6 +36,30 @@ class MailingsControllerTest < ActionDispatch::IntegrationTest
|
||||
assert_match(/1 ultimi 15 min/, response.body)
|
||||
assert_select "div", text: "Storico invio"
|
||||
assert_match(/1 inviate · ultime 12 ore/, response.body)
|
||||
assert_select "span", text: "12h"
|
||||
assert_select "a", text: "24h"
|
||||
assert_select "a", text: "7g"
|
||||
end
|
||||
|
||||
test "dashboard history range can switch to the last week" do
|
||||
login_as users(:admin)
|
||||
follow_redirect! if response.redirect?
|
||||
|
||||
mailing = create_mailing(identity: @identity, audience: "to_send")
|
||||
org = organizations(:acme)
|
||||
mailing.mailing_recipients.create!(
|
||||
organization: org,
|
||||
contact: org.contacts.first,
|
||||
email: org.email,
|
||||
status: "sent",
|
||||
sent_at: 2.days.ago
|
||||
)
|
||||
|
||||
get dashboard_mailings_path(project_code: @project.code, history: "7d")
|
||||
assert_response :success
|
||||
assert_match(/1 inviate · ultima settimana/, response.body)
|
||||
assert_select "span", text: "7g"
|
||||
assert_select "a[href=?]", dashboard_mailings_path(project_code: @project.code, history: "24h")
|
||||
end
|
||||
|
||||
test "creates a draft and opens audience filters" do
|
||||
|
||||
Reference in New Issue
Block a user