forked from spree-contrib/spree_drop_ship
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updates to cleanup stuff that should be in marketplace.
- Loading branch information
Jeff Dutil
authored and
Jeff Dutil
committed
Jul 23, 2014
1 parent
e1a133a
commit caec60b
Showing
8 changed files
with
45 additions
and
33 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 0 additions & 17 deletions
17
app/overrides/spree/users/show/add_supplier_info.html.erb.deface
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
require 'spec_helper' | ||
|
||
describe 'Admin - DropShip Settings', js: true do | ||
|
||
before do | ||
login_user create(:admin_user) | ||
|
||
visit spree.admin_path | ||
within 'ul[data-hook=admin_tabs]' do | ||
click_link 'Configuration' | ||
end | ||
within 'ul[data-hook=admin_configurations_sidebar_menu]' do | ||
click_link 'Drop Ship Settings' | ||
end | ||
end | ||
|
||
it 'should be able to be updated' do | ||
# Change settings | ||
uncheck 'send_supplier_email' | ||
fill_in 'default_commission_flat_rate', with: 0.30 | ||
fill_in 'default_commission_percentage', with: 10 | ||
click_button 'Update' | ||
expect(page).to have_content('Drop ship settings successfully updated.') | ||
|
||
# Verify update saved properly by reversing checkboxes or checking field values. | ||
check 'send_supplier_email' | ||
click_button 'Update' | ||
find_field('default_commission_flat_rate').value.to_f.should eql(0.3) | ||
find_field('default_commission_percentage').value.to_f.should eql(10.0) | ||
expect(page).to have_content('Drop ship settings successfully updated.') | ||
end | ||
|
||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters