Fix recalculating included tax adjustments. Fixes #4671
Admin::Orders test completed? instead of complete?

Checkout steps are customizable, 'complete' may not be the only state in
which an order is considered complete.

Fixes #4751
added 'through: :stock_items' to 'has_many :stock_movements' relation in variant class

Fixes #4707
Regression spec for variant stock_movements relation
Use current_store.url for Google Analytics.
Fix html safe when cart is empty
Use the payments currency rather than config for multi-currency.
Added data-hooks where values were empty and fixed some repeated ids.

Fixe #4573
Use the root_object instead of @line_item.

This is the object the other views use for caching.
Use root object for credit card caching
Fix broken cache on api/orders

The cache keys were not unique anymore because we were passing nil, e.g.
`@order` is not defined when rendering api/orders.json, same thing
happened with all nested objects using a instance var instead of rabl
`root_object`

Fixes #4757
Populate Order#shipment_total for users upgrading

Previous to Spree 2.2 orders didn't have a shipment_total. This should
populate that new column for legacy orders

Fixes #4684
Pass in order params on order creation so they can be overridden

Fixes #4693
remove reference to shipment.adjustment

shipment.adjustment no longer exists so we can kill this. also wasn't
tested, so no need to change test cases.

My understanding is with the adjustment refactoring we don't need to
deal with the open/close anymore anyway.
handle credit card names with spaces

this addresses a change from https://github.com/spree/spree/commit/71d4deed1aa815a2727357f2c35e2f544f5f1959

Fixes #4770
Update payment state any time a completed order item change

Fixes #4411
Fixes entering localized amounts for payments

While running Spree in Dutch locale, adding a Payment recognizes the decimal separator as thousands separator. So when using the pre filled value (e.g. 45.21) this will be converted to a much larger amount (4521.00). The fix makes sure that a localized value is filled in (45,21 instead of 45.21).

Tested on Spree 2.2.1

Fixes #4753
Add top level rake task to run all tests
credit card spec fix

fixes #4778
fix for payments made via /admin

orders placed via /admin were being charged twice.

See these two lines from Spree::Admin::PaymentsController:

    while @order.next; end
    @payment.process! if @order.completed?

For incomplete orders the first line will trigger callbacks that cause
the payment to be charged if the order reaches the "completed" state.
Then the second line will process the payment *again*, resulting in a
double charge.

We can't just remove the second line because orders that are already
complete won't trigger any callbacks from the first line, so these
orders need to have their payments charged manually.

The effect of the bug in our case was that Braintree rejected the second
(duplicate) billing on the payment, and this resulted in the Payment
object being marked as failed when actually it succeeded on the first
attempt. So it appeared from within Spree that a successful payment
was a failed payment.

Fixes #4768