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

feat: Initial WinApiLayer with some methods #15

Merged
merged 4 commits into from
Apr 22, 2024

Conversation

FrogTheFrog
Copy link
Collaborator

Description

Added the initial WinApiLayer that will act as the final layer between the code and OS.

WinApiLayer will have some basic testing, but not all code paths will be verified as it will be pain in the a** to mock the dreadful WinAPI...

Also applied some suggestions from CLion regarding consts.

Finally, removed this preamble:

/**
 * @file utils.cpp
 * @brief Utility functions
 */

Please, let's not use it in this library as it is the most useless thing and I hate it :'( . It always boils down to this description:
"filename.cpp" -> "Implements the class/functions"

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Dependency update (updates to dependencies)
  • Documentation update (changes to documentation)
  • Repository update (changes to repository files, e.g. .github/...)

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated the in code docstring/documentation-blocks for new or existing methods/components

Branch Updates

LizardByte requires that branches be up-to-date before merging. This means that after any PR is merged, this branch
must be updated before it can be merged. You must also
Allow edits from maintainers.

  • I want maintainers to keep my branch updated

@FrogTheFrog

This comment was marked as resolved.

Copy link

codecov bot commented Apr 20, 2024

Codecov Report

Attention: Patch coverage is 35.23810% with 68 lines in your changes are missing coverage. Please review.

Project coverage is 45.45%. Comparing base (aa5a95f) to head (f49a393).

Additional details and impacted files
@@             Coverage Diff             @@
##           master      #15       +/-   ##
===========================================
- Coverage   67.34%   45.45%   -21.90%     
===========================================
  Files           2        5        +3     
  Lines          49      154      +105     
  Branches       17       89       +72     
===========================================
+ Hits           33       70       +37     
- Misses          2        7        +5     
- Partials       14       77       +63     
Flag Coverage Δ
Windows 45.45% <35.23%> (-21.90%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
src/logging.h 50.00% <ø> (ø)
src/platf/windows/winapilayer.h 100.00% <100.00%> (ø)
src/platf/windows/winapilayerinterface.h 100.00% <100.00%> (ø)
src/platf/windows/winapilayer.cpp 33.98% <33.98%> (ø)

Copy link
Member

@ReenigneArcher ReenigneArcher left a comment

Choose a reason for hiding this comment

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

I think the coverage results are a little inaccurate. Trying to work through that for Sunshine as well in gcovr/gcovr#915

tests/utils.cpp Outdated Show resolved Hide resolved
tests/conftest.cpp Outdated Show resolved Hide resolved
src/platf/windows/winapilayer.cpp Outdated Show resolved Hide resolved
tests/unit/platf/windows/test_winapilayer.cpp Outdated Show resolved Hide resolved
@ReenigneArcher ReenigneArcher merged commit 35ca85a into LizardByte:master Apr 22, 2024
14 of 16 checks passed
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.

2 participants