-
Notifications
You must be signed in to change notification settings - Fork 5
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
Refactor Hydra token introspection #92
Conversation
This moves the Hydra Admin API helper into a separate library, using more idiomatic call for Faraday. It does mean that when testing the auth token has to be given in the headers.
…Foundation/choco-cake into refactor-hydra-introspection
@@ -25,3 +25,5 @@ RSpec/DescribeClass: | |||
- "spec/graphql/queries/**" | |||
- "spec/graphql/mutations/**" | |||
|
|||
RSpec/MultipleMemoizedHelpers: | |||
Max: 8 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of upping this could you not refactor the tests a bit?
So in the images_spec you don't really need the image_filename
and instead could do
let(:params) { { images: [fixture_file_upload('test_image_1.png', 'image/png')] } }
etc as it's not referenced in any tests.
Same for the update spec. You could remove the default_component_params
and put them straight into the params
as they are not being used in the tests I don't think.
Unless we wanted it increased of course :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think there are more places where we use a lot of memoized helpers. I don't feel to bad about upping the number. We should discuss this though..
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@patch0 Yeah I'm fine with it being increased to 8. There's already a few PR's in need of that from your overly productive day yesterday 😅 Just some autocorrectable offences to fix!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🥇
What's changed
oauth_user
helper intoidentifiable
concern to use the Hydra Admin API library introduced in Add a GraphQL endpoint #134Points for consideration