@@ -151,9 +151,9 @@ test('Create Account form - phone number from order shipping address is saved to
151151 expect ( registrationRequestBody ) . not . toBeNull ( )
152152 } )
153153
154- // Verify that the phone number from the order's shipping address is included in the registration
154+ // Verify that the phone number from the order's billing address is included in the registration
155155 expect ( registrationRequestBody . customer . phoneHome ) . toBe (
156- mockOrder . shipments [ 0 ] . shippingAddress . phone
156+ mockOrder . billingAddress . phone
157157 )
158158 expect ( registrationRequestBody . customer . phoneHome ) . toBe ( '(778) 888-8888' )
159159
@@ -176,7 +176,7 @@ test('Integration test - phone number from order is visible in customer account
176176 email : mockOrder . customerInfo . email ,
177177 firstName : mockOrder . billingAddress . firstName ,
178178 lastName : mockOrder . billingAddress . lastName ,
179- phoneHome : mockOrder . shipments [ 0 ] . shippingAddress . phone ,
179+ phoneHome : mockOrder . billingAddress . phone ,
180180 login : mockOrder . customerInfo . email
181181 }
182182 return res ( ctx . status ( 200 ) , ctx . json ( savedCustomerData ) )
@@ -198,7 +198,7 @@ test('Integration test - phone number from order is visible in customer account
198198 lastName : mockOrder . billingAddress . lastName ,
199199 address1 : mockOrder . shipments [ 0 ] . shippingAddress . address1 ,
200200 city : mockOrder . shipments [ 0 ] . shippingAddress . city ,
201- phone : mockOrder . shipments [ 0 ] . shippingAddress . phone ,
201+ phone : mockOrder . billingAddress . phone ,
202202 postalCode : mockOrder . shipments [ 0 ] . shippingAddress . postalCode ,
203203 stateCode : mockOrder . shipments [ 0 ] . shippingAddress . stateCode ,
204204 countryCode : mockOrder . shipments [ 0 ] . shippingAddress . countryCode
@@ -245,7 +245,7 @@ test('Integration test - phone number from order is visible in customer account
245245 // and verifying the phone number is displayed in the UI, but that would require
246246 // additional setup of the Account page component and its dependencies.
247247
248- // The key assertion is that the phone from the order's shipping address
249- // is correctly saved to the customer's phoneHome field during registration
250- expect ( savedCustomerData . phoneHome ) . toBe ( mockOrder . shipments [ 0 ] . shippingAddress . phone )
248+ // The key assertion is that the phone from the order's billing address
249+ // is correctly saved to the customer's phoneHome field during registration
250+ expect ( savedCustomerData . phoneHome ) . toBe ( mockOrder . billingAddress . phone )
251251} )
0 commit comments