Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restore destroy functionality #1690

Merged
merged 1 commit into from
Jun 30, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions app/assets/javascripts/administrate/application.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
//= require jquery
//= require jquery_ujs
nickcharlton marked this conversation as resolved.
Show resolved Hide resolved
//= require selectize
//= require moment
//= require datetime_picker
Expand Down
1 change: 1 addition & 0 deletions spec/example_app/app/assets/javascripts/application.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,5 @@
// about supported directives.
//
//= require jquery
//= require jquery_ujs
nickcharlton marked this conversation as resolved.
Show resolved Hide resolved
//= require_tree .
2 changes: 1 addition & 1 deletion spec/features/log_entries_index_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
expect(current_path).to eq(new_admin_log_entry_path)
end

scenario "user deletes record" do
scenario "user deletes record", js: true do
create(:log_entry)

visit admin_log_entries_path
Expand Down
4 changes: 2 additions & 2 deletions spec/features/orders_index_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
expect(current_path).to eq(new_admin_order_path)
end

scenario "user deletes record" do
scenario "user deletes record", js: true do
create(:order)

visit admin_orders_path
Expand All @@ -56,7 +56,7 @@
)
end

scenario "cannot delete because associated payment" do
scenario "cannot delete because associated payment", js: true do
create(:payment, order: create(:order))

visit admin_orders_path
Expand Down
4 changes: 4 additions & 0 deletions spec/rails_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -37,4 +37,8 @@ module Features
Capybara::Poltergeist::Driver.new(app, options)
end

Capybara.register_driver :rack_test do |app|
Capybara::RackTest::Driver.new(app, respect_data_method: false)
end

Capybara.server = :webrick