-
Notifications
You must be signed in to change notification settings - Fork 0
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
[Track 7/9] User query #25
Comments
Finish |
Step 2/3 - The testsEstimated time: 2 hourNow it's time to test your query and all its possible scenarios. Write tests to verify it's working. Again: try to make independent tests, setting up your database before each one according to what you want to test. |
Finish |
Step 3/3 - Challenge: seedEstimated time: 3 hours[Spoiler alert]: your next track is about writing a query to list users. But in order to do that, you should have users on database (and a lot of them), right? Well, you could use your recently implemented mutation The idea is to write some code to populate your database, creating an environment to facilitate your
NOTE: don't forget that you have to connect with the database in order to run the code, right? You can check on TablePlus if your script worked. One thing that can help you with this code is Faker: a library that has some cool features to return several kinds of randomic data you want, like names, websites, numbers, sentences, and a lot more. NOTE 2: this is an example of task that we use the |
Finish |
Click here for your next track |
Step 1/3 - The query
Estimated time: 2 hours
This is the first query you're going to implement on the project. After logging in and creating user, now it's time to provide a query for fetching a user information. Some details:
user
Unlike the previous tracks, now you're going to write the query prototype and integrate with the database already.
NOTE: don't forget to predict error cases. In this query, the most obvious one is passing an id that is not found on database.
The text was updated successfully, but these errors were encountered: