716-Energy-Tests #1113
No reviewers
Labels
No labels
_CRITICAL_
API
app
backEnd
Blocked, waiting for further changes
bug
cleanup
close
design
duplicate
enhancement
feature request
frontEnd
help wanted
invalid
low priority
needs input
needs review
project documentation
question
research
reviewed
script
security
SQL
style
testing
topLevel
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Andras/BoundlessFlowCampus2K!1113
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "716-Energy-Tests"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Big PR? on the last 2 days? with multiple brand new complicated tolls??? all true and a classic 😄
related issue #716
Giga pull request, i tried to be as detailed as possible in code comments as its alot of information to share here. Essentially a functional creation of integration testing with real databases using xunit, ASP core and testcontainers. Not alot of tests were added, but i dont have enough time to do everything so i focused on making the bigger checks (integration and http requests possible) fututre developers will be able to look at this and expand and create integration tests for other services similar to energy
you can also make unit tests with this, as that is just test desing strcucture but using real databases for unit tests is kinda overkill, possible but maybe look more to the moq side of testing for that, but i included test examples for both unit and integration.
Monday is full focus on creating a wiki page for this to explain functions to future developers
to run tests go cd into energyService.Tests and just run dotnet test (sudo dotnet tests if you access errors) in the terminal
The tests looks good as base start on how to create an integration test:
after that is done. I can approve this pr
@ -58,3 +58,4 @@ app.UseAuthorization();*/EnergyEndpoints.MapEnergyEndpoints(app);app.Run();public partial class Program { }add a comment here why this is needed for the test so that it is clear when we handover to next group
created new issues
added clarifying comments
added a read me explaining how to run tests and know errors and how to solve them
Great!
Very good job!
Now we have a good base for integration test that is implemented and actually works.