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

refactor: cleaned up Unit Tests #948

Merged
merged 13 commits into from
Oct 21, 2023
Merged

Conversation

professor91
Copy link
Contributor

@professor91 professor91 commented Oct 14, 2023

PR for restructuring unit tests into smaller files

Code change checklist

  • I have ensured that all methods and functions are fully documented using doxygen style comments.
  • My code follows the coding style guide.
  • I tested that my change works before raising the PR.
  • I have ensured that I did not break any existing API calls.
  • I have not built my pull request using AI, a static analysis tool or similar without any human oversight.

@netlify
Copy link

netlify bot commented Oct 14, 2023

Deploy Preview for dpp-dev ready!

Name Link
🔨 Latest commit 8ce1b00
🔍 Latest deploy log https://app.netlify.com/sites/dpp-dev/deploys/6532d77df32d4b000887b672
😎 Deploy Preview https://deploy-preview-948--dpp-dev.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@professor91 professor91 marked this pull request as draft October 14, 2023 23:13
@github-actions github-actions bot added documentation Improvements or additions to documentation build Issue or Pull Request related to the build process code Improvements or additions to code. labels Oct 14, 2023
@braindigitalis braindigitalis linked an issue Oct 14, 2023 that may be closed by this pull request
@professor91 professor91 marked this pull request as ready for review October 19, 2023 15:42
Copy link
Contributor

@Jaskowicz1 Jaskowicz1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're gonna have the word "space indentation" stuck in your head after this one :P

src/unittest/discord_objects.cpp Outdated Show resolved Hide resolved
src/unittest/gateway_events.cpp Outdated Show resolved Hide resolved
src/unittest/gateway_events.cpp Show resolved Hide resolved
src/unittest/http.cpp Outdated Show resolved Hide resolved
src/unittest/utilities.cpp Outdated Show resolved Hide resolved
src/unittest/discord_objects.cpp Outdated Show resolved Hide resolved
Copy link
Contributor

@braindigitalis braindigitalis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CI is failing due to codacy static analysis warnings, you have to fix these before it can me merged alongside the style changes.

@Mishura4
Copy link
Member

CI is failing due to codacy static analysis warnings, you have to fix these before it can me merged alongside the style changes.

"condition is always true" can't be fixed in runtime unit tests. Those are the point of tests, the condition should be true.
One way you could fix them is turn them into static_asserts i suppose

@braindigitalis braindigitalis dismissed their stale review October 20, 2023 12:15

codacy made to pass now

@Jaskowicz1 Jaskowicz1 changed the title Unit test tidyup refactor: cleaned up Unit Tests Oct 20, 2023
@Jaskowicz1
Copy link
Contributor

I've corrected the title to accurately reflect our standards. I've also changed the description as this is no longer a draft PR.

@professor91
Copy link
Contributor Author

changed all space indents to tabs
thanks for helping out @Jaskowicz1 @Mishura4 !!

Copy link
Member

@Mishura4 Mishura4 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not a fan of functions without parameter names in test.h but the rest looks good to me.

@braindigitalis braindigitalis merged commit 359ce61 into brainboxdotcc:dev Oct 21, 2023
36 checks passed
braindigitalis added a commit that referenced this pull request Oct 22, 2023
@Jaskowicz1 Jaskowicz1 removed a link to an issue Oct 30, 2023
@Jaskowicz1 Jaskowicz1 mentioned this pull request Feb 11, 2024
5 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build Issue or Pull Request related to the build process code Improvements or additions to code. documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants