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

Add Functional Tests for Author Endpoints #1

Closed
ardalis opened this issue Feb 9, 2020 · 8 comments
Closed

Add Functional Tests for Author Endpoints #1

ardalis opened this issue Feb 9, 2020 · 8 comments
Labels
good first issue Good for newcomers help wanted Extra attention is needed

Comments

@ardalis
Copy link
Owner

ardalis commented Feb 9, 2020

Use this as a model/starting point:
https://github.com/ardalis/CleanArchitecture/blob/master/tests/CleanArchitecture.FunctionalTests/Api/ApiToDoItemsControllerList.cs

@ardalis ardalis added good first issue Good for newcomers help wanted Extra attention is needed labels Feb 9, 2020
@KyleMcMaster
Copy link
Contributor

I'll take a shot at implementing these functional tests! 😃

@ardalis
Copy link
Owner Author

ardalis commented Feb 12, 2020

Go for it!

@ardalis
Copy link
Owner Author

ardalis commented Feb 13, 2020

By the way, any estimate on turnaround time?

@KyleMcMaster
Copy link
Contributor

@ardalis I finished the get and list tests, but I ran into some issues with the create, delete, and update tests. I can open the PR for reference, but my issue is the in memory database provider causes some synchronization issues when the tests run. So when I run the create test, the total count of Authors is incremented which breaks the list test. Same goes for delete tests when it decrements the Author list count. I would appreciate any thoughts or feedback on how to approach these functional tests.

@ardalis
Copy link
Owner Author

ardalis commented Feb 13, 2020

If you want to PR just the read-only method tests that's fine.

If you want an example of some tests that I'm pretty sure work properly, look here:
https://github.com/ardalis/CleanArchitecture/tree/master/tests/CleanArchitecture.FunctionalTests

and also (older) here:
https://github.com/ardalis/GettingStartedWithFilters/tree/master/IntegrationTests

@KyleMcMaster
Copy link
Contributor

Published the existing PR for get and list tests only for right now. If I have some additional availability over the next few days I'll gladly pick up the create, delete, and update tests if someone hasn't done them already.

@jeastham1993
Copy link
Contributor

Happy to pick this up as well @ardalis for the create, update and delete methods

ardalis pushed a commit that referenced this issue Apr 29, 2020
* Add support for multiple query parameters #15

* Remove redundant pagination request model

* Functional tests for Create, Delete and Update #1

Co-authored-by: James Eastham <j.eastham1993@gmail.com>
@ardalis
Copy link
Owner Author

ardalis commented Apr 29, 2020

Thanks!

@ardalis ardalis closed this as completed Apr 29, 2020
ardalis pushed a commit that referenced this issue Apr 15, 2021
* add dependabot

* adjust the open pull requests limit for nuget
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants