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

CF-544 Create User Testing #4

Draft
wants to merge 5 commits into
base: qa
Choose a base branch
from
Draft

CF-544 Create User Testing #4

wants to merge 5 commits into from

Conversation

sheilf-synapse
Copy link

@sheilf-synapse sheilf-synapse commented Dec 23, 2022

Task Link: CF-545

<!-- Run "php synapse_rest/customModule.php" to create a user on integrationy via PHP script -->
<!-- Run  "php vendor/bin/phpunit synapse_rest/test.php"  to create a user on integrationy via Test class -->

Description:

All tests were commented out. It's not clear why that was. There's two potential reasons why:

  • clients may be pulling or forking the repo and creating their own tests (this seems like developer experience with friction)
  • tests were not in a stable condition and they were removed

Test method: testCreateUser()
When uncommenting the tests, I ran into a series of undefined errors across all tests and the constructor. It appeared that there were some structural failures with the API wrapper as it was running into numerous object mismatching and undefined exceptions. The isSet(var) additions in the code are all examples of object mismatching that occurred for one method.

The method was also using unexpected arguments while expecting to pass:

// current use
$testObj = $client->create_user($logins_object, $phoneNumbers_array, $legalnames_array );

// method
function create_user($body, $idempotency_key=null, $newFingerPrint=null) {}

// fix
$testObj = $client->create_user($body);

image

There's a number of things we can do:

  1. Find out if anyone is using the PHP wrapper at all. Slack communications only has a history of use with Microventures years ago, who is still one of our clients, so that may provide useful insight.

  2. Rebuild/refactor the PHP wrapper for stability if the demand is there but the satisfaction is not.

image

@sheilf-synapse sheilf-synapse changed the base branch from master to qa December 23, 2022 22:29
@sheilf-synapse sheilf-synapse changed the title Cf 544 CF-544 Create User Testing Dec 23, 2022
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.

1 participant