Include sample in top level rake test and test_app
add missing respond_with to some API controllers and add tests

update spec to test custom rabl template

inject custom view into dummy app

ensure usage of respond_with for orders and inventory_units

Conflicts:

	api/spec/controllers/spree/api/products_controller_spec.rb

add respond_with to ProductsController

test through custom action instead

remove fileutils
Reimbursement updates

- Fix Reimbursement to inherit from Spree::Base
- Change Reimbursement tax calculator to receive the reimbursement instead of just the array of return items
  - This assists some systems like Avatax which may want more context
- Fix reimbursement create form to only try to include accepted items

Fixes #5123
Implement exchanges.

Fixes #5073
remove preference "shipment_inc_vat" and corresponding controller, view, route, translations
Fixes #5127

Conflicts:
	core/app/models/spree/app_configuration.rb
Associate default user address in pre-transition callback

Two advantages:

1) Centralizes this logic, as we want this to happen whether you create
an order from frontend, backend or API.

2) Waits until the last possible moment to assign an address and will
thus get the most recent default address, rather than the one at the
time the cart was created.

Make default address association safer

It turns out that the state transition itself calls a save, so there is
no need to add one more here. To make this even safer, we refuse to
associate default addresses that are not valid.

Save two queries by checking _id instead of the association

Convert to new hash syntax

Fixes #5108
Make Shipment.cost default to 0

Since upgrading to Spree 2.2, I've noticed exceptions getting thrown by, for instance [`cost + promo_cost`](https://github.com/spree/spree/blob/2-2-stable/core/app/models/spree/shipment.rb#L151) throwing `NoMethodError: undefined method `+' for nil:NilClass`.

Looking into my db schema, I see that virtually all decimal figures in Spree default to 0, but it looks like for some reason `spree_shipments.cost` didn't get that default. This migration helps ensure a smooth upgrade path from earlier Spree releases to 2.2.

Fixes #5128
Add completed back as default state.
Attempt to auto-accept return items when received.
Fixes #5130
Update gem options to Ruby 1.9 syntax

:lipstick:

Fixes #5134
Fix broken specs.
Specs for ReimbursementPerformer

- Add specs for ReimbursementPerformer
Reimbursement Admin UI updates

- Don't show edit button for reimbursement if reimbursement has been finalized
- Add an admin reimbursements show page
Fix rounding issue

Add some rounding in reimbursements to handle edge cases where multiple consecutive partial refunds
on the same order might result in rounding errors where we'd reimburse more than was originally
billed.

Fixes #5131
Add missing translation

Specs were complaining like this: https://gist.github.com/jordan-brough/336daa1b1648dd8609e8
Fixes #5135
Allow assigning shipped_at to shipments.
Don't crash if there is no address to associate

Rather, just do nothing. This prevents a crash we've seen in production at
Bonobos.

Fixes #5137
Merge pull request #5101 from themetric/fix-api-custom-template

add missing respond_with to some API controllers and add tests
goodbye aws-sdk one less core dependency
Merge pull request #4844 from woboinc/bugfix/avoid_name_clashing

Avoid name clashing when including modules
Conflicts:
	core/app/models/spree/order.rb