We still have a couple of broken tests, see http://qa.drupal.org/pifr/test/130769

Currency code has been correctly modified	Browser	commerce_order_ui.test	220	CommerceOrderUIAdminTest->testCommerceOrderUIUpdateLineItems()
Undefined variable: class	Notice	commerce_cart.module	1835	commerce_cart_add_to_cart_form_attributes_refresh()

Comments

rszrama’s picture

Part of this was a duplicate that I detected earlier today of: #1280894-9: Better formatting for product_reference multi-value field wrappers

I'm running the Order admin test locally now. Not sure why a test would suddenly fail to change a currency. :-/

rszrama’s picture

Title: Broken tests (now that tests work :-) » Line item manager validation does not save currency change if price doesn't change
Status: Active » Fixed

And, in fact, I'm not getting any fails in the Order UI tests locally. But that could just be because of the way the test is using randomization. We really need to go through and remove all elements of randomization when we're trying to compare values - as is, we leave open the possibility for the random "updated" value to be the same as the first. If we know we want to test a different value, we should just hard code values.

The actual fix involved changing the logic in the validate handler for the line item manager so that it saves an updated price if just the currency changes. Right now it only saves it if the amount changes.

Commit: http://drupalcode.org/project/commerce.git/commitdiff/25061da

rfay’s picture

And we have passing tests! http://qa.drupal.org/pifr/test/130769

YAY!

rfay’s picture

And FIFTY (50) queued commerce patches now :-)

Automatically closed -- issue fixed for 2 weeks with no activity.