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

Test helper for relationships #27

Closed
ma0ho opened this issue Nov 4, 2016 · 4 comments
Closed

Test helper for relationships #27

ma0ho opened this issue Nov 4, 2016 · 4 comments
Milestone

Comments

@ma0ho
Copy link

ma0ho commented Nov 4, 2016

I'm not sure if I haven't found them or if they do not exist yet. Are there any helpers to test the relationship retrieval/creation/update of an resource. I would expect something like doReadRelationship(). If thats missing (and not coming very soon) I would implement that on my own and can, of course, create a pull request..

@lindyhopchris
Copy link
Member

Hi! Sorry for slow reply - missed this issue being created.

They don't exist at the mo but definitely my intention to add some in. I need to do quite a bit of work around the relationship endpoints as there's a few things missing for them at the mo.

Thanks for the offer of a pull request. If you wanted/have time to submit one then it'd be very welcome. As you say, the method names would be along the same names as the existing one on InteractsWithResources, so:

  • doReadRelatedResource
  • doReplaceRelationship
  • doAddToRelationship
  • doRemoveFromRelationship

i.e. match the controller method names as defined here:
https://github.com/cloudcreativity/laravel-json-api/wiki/Routing

Obviously happy to help out with questions/review if needed. If you're not able to submit a pull request then these are definitely on my to-do list.

@lindyhopchris lindyhopchris added this to the 0.6.0 milestone Nov 8, 2016
@ma0ho
Copy link
Author

ma0ho commented Nov 8, 2016

Hey! Thanks for your reply. I think I can work on that in the near
future. Doesnt seem to be too much work to me. Unfortunately there are
some other things that come first. So might take a little time to get
this done. I come back to you soon.

Am Di, 8. Nov, 2016 um 11:09 schrieb Christopher Gammie
[email protected]:

Hi! Sorry for slow reply - missed this issue being created.

They don't exist at the mo but definitely my intention to add some
in. I need to do quite a bit of work around the relationship
endpoints as there's a few things missing for them at the mo.

Thanks for the offer of a pull request. If you wanted/have time to
submit one then it'd be very welcome. As you say, the method names
would be along the same names as the existing one on
InteractsWithResources, so:

doReadRelatedResource
doReplaceRelationship
doAddToRelationship
doRemoveFromRelationship
i.e. match the controller method names as defined here:
https://github.com/cloudcreativity/laravel-json-api/wiki/Routing

Obviously happy to help out with questions/review if needed. If
you're not able to submit a pull request then these are definitely on
my to-do list.


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.

@lindyhopchris
Copy link
Member

that's ok - don't worry if it takes a bit of time. I'm also tied up with work deadlines this month anyway, so probably won't be looking at the next step of development for this until December anyway

@lindyhopchris lindyhopchris mentioned this issue May 18, 2017
15 tasks
@lindyhopchris
Copy link
Member

Closing this because test helpers for relationship requests are now on the 1.x-dev branch

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants