Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support solidus 3.0 #122

Merged

Conversation

DanielePalombo
Copy link
Contributor

No description provided.

@DanielePalombo DanielePalombo self-assigned this Apr 26, 2021
@DanielePalombo DanielePalombo force-pushed the fix-deprecated-fullname branch 6 times, most recently from 68e1de4 to 05a4876 Compare April 26, 2021 20:55
@DanielePalombo DanielePalombo marked this pull request as ready for review April 26, 2021 21:04
Copy link

@Jecko-o Jecko-o left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @DanielePalombo , leaving a question, hope it helps


it { expect { to_json }.not_to raise_error }

if Spree.solidus_gem_version >= Gem::Version.new(2.11)
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Couldn't we use two contexts with different Spree.solidus_gem_version?
This way the whole functionality would always be tested, and not dependently of the bundle when running the tests.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I had made two contexts would mean that I have had stub the Spree.solidus_gem_version, in that way I can test the method as BlackBox.

Copy link
Member

@elia elia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mostly nits and questions

@Jecko-o
Copy link

Jecko-o commented May 10, 2021

It seems this PR meets all the requirements now, I hope it will be approved soon enough. Support for solidus 3.0 is necessary to work with this extension. Keep on the good work!

@RyanofWoods
Copy link
Contributor

RyanofWoods commented Dec 1, 2021

@DanielePalombo
Copy link
Contributor Author

Hi @DanielePalombo 👋 The call to name gives bill_address as an argument:

https://github.com/solidusio-contrib/solidus_paypal_commerce_platform/blob/35524e86421e22258ca3e0081400b17c6bca7c9c/app/models/solidus_paypal_commerce_platform/paypal_order.rb#L40

But from this commit, if the Solidus version is greater than 2.10, then the ship_address will be used instead of the given argument. Is there a specific reason for this?

https://github.com/solidusio-contrib/solidus_paypal_commerce_platform/blob/35524e86421e22258ca3e0081400b17c6bca7c9c/app/models/solidus_paypal_commerce_platform/paypal_order.rb#L48

@RyanofWoods nice catch, I don't see any spec around this behavior so I assume this is just an error.

RyanofWoods added a commit to RyanofWoods/solidus_paypal_commerce_platform that referenced this pull request Feb 4, 2022
On the following line, the billing address is given to the name method.
https://github.com/solidusio-contrib/solidus_paypal_commerce_platform/blob/64be7ddb4967a93155c035430101d4bbfce83313/app/models/solidus_paypal_commerce_platform/paypal_order.rb#L40

The following commit accidentally started using the order's
ship_address instead of the given billing address when Solidus' version
is >= 2.11.
solidusio@63fe8f9

Reference:
solidusio#122 (comment)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants