-
Notifications
You must be signed in to change notification settings - Fork 754
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
Add GraphQL Client #331
Add GraphQL Client #331
Conversation
I know this will sound really picky, but I'd prefer to see them named 'v3client' and 'v4client'; the API protocol is just an artifact, it's not really the differentiating factor between them the API version is. Imagine what will happen if GitHub releases as V5 API which is also GraphQL based :-) |
Makes sense. |
18c5f59
to
62ad72f
Compare
62ad72f
to
6537ed7
Compare
|
@patrickmarabeas - I've got this queued to remove conflicts early next week. Happy to merge if you beat me to it 😄 |
Was hoping to get to it today but failed miserably. |
74c54cd
to
55b7062
Compare
@jcudit rebased and conflicts resolved. |
Caught a bunch of these when running acceptance tests locally ☝️ |
2de7342
to
130397f
Compare
Soz, assumed CI was running acceptance tests. Tests no longer panicking, but I am getting some failures - most look to be because I have previously run the tests and things are already in the state it is trying to put them into. The only error looks to be the following, which is related to my addition of adding
Is it possible to update the mock API URL to include the I'll continue to dig into it later tonight if you don't beat me to it. |
I'm encountering the above error (sans |
Adding something like the following to this function should get the test passing: mux.HandleFunc("/v3/users/hashibot", testRespondJson(userResponseBody))
mux.HandleFunc("/v3/users/hashibot/gpg_keys", testRespondJson(gpgKeysResponseBody))
mux.HandleFunc("/v3/users/hashibot/keys", testRespondJson(keysResponseBody))
mux.HandleFunc("/v3/orgs/", testRespondJson("{}"))
I had to set this in my environment or a panic occurs during Can't spot much else. I think this one is pretty close to shipping. |
This will allow for resources and data sources to be uplifted on a case by case basis. * Add shurcool/graphqlv4 * Initialize a GraphQL client (v4client) * Rename client to v3client
Update acceptance testing documentation to include the exporting of the GITHUB_BASE_URL environment variable.
130397f
to
a73dbfa
Compare
I don't think that's it. I get the same error on master. Are you seeing similar errors on your end? Prepending
Is it possible to get acceptance tests running on this PR? I notice they seem to run on some, but not others... |
@patrickmarabeas I gotcha! i just added the acceptance test label - let's see if/how they run :) ah i see the tests erroring out b/c the ENV |
Ahh. 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 propose we track the failing TestProvider_insecure
test elsewhere and move forward with these changes as-is since master
looks to be failing similar to how this branch fails. Other feature work can then proceed with the foundation this work lays and we can revisit additional functionality when a better design emerges.
I'll leave this approval around until you confirm this is an acceptable approach and hope to merge by end of week.
Add GraphQL Client
Initialize a client for Github GraphQL API calls. This will allow for resources and data sources to be uplifted on a case by case basis.