Skip to content

Commit 90a1f3e

Browse files
committed
fix spec
1 parent 667f011 commit 90a1f3e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

spec/system/banners/new_spec.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
click_on "New Banner"
3939
fill_in "Name", with: "Expiring Announcement"
4040
check "Active?"
41-
fill_in "banner_expires_at", with: 7.days.from_now.strftime("%Y\t%m%d%I%M%P")
41+
find("#banner_expires_at").execute_script("this.value = arguments[0]", 7.days.from_now.strftime("%Y-%m-%dT%H:%M"))
4242
fill_in_rich_text_area "banner_content", with: "Please fill out this survey."
4343
click_on "Submit"
4444

@@ -47,7 +47,7 @@
4747
within "#banners" do
4848
click_on "Edit", match: :first
4949
end
50-
fill_in "banner_expires_at", with: 3.days.from_now.strftime("%Y\t%m%d%I%M%P")
50+
find("#banner_expires_at").execute_script("this.value = arguments[0]", 3.days.from_now.strftime("%Y-%m-%dT%H:%M"))
5151
click_on "Submit"
5252

5353
expect(page).to have_text("Expiring Announcement Yes in 3 days")
@@ -62,7 +62,7 @@
6262
visit banners_path
6363
click_on "New Banner"
6464
fill_in "Name", with: "Announcement not created"
65-
fill_in "banner_expires_at", with: 1.week.ago.strftime("%Y\t%m%d%I%M%P")
65+
find("#banner_expires_at").execute_script("this.value = arguments[0]", 1.week.ago.strftime("%Y-%m-%dT%H:%M"))
6666
fill_in_rich_text_area "banner_content", with: "Please fill out this survey."
6767
click_on "Submit"
6868

0 commit comments

Comments
 (0)