-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Fix compiler warning and add missing includes in unit test environment #4747
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
All values in bytes. Δ Delta to base
|
I think it would be useful to start stubbing the EEPROM functions... they are easily getting in the way :) |
Draft... I'm gonna add a few more simple fixes. (Like missing stdint include) |
gudnimg
force-pushed
the
minor-fixes-for-future-tests
branch
2 times, most recently
from
August 8, 2024 15:00
0331f43
to
a23b7bc
Compare
gudnimg
changed the title
Fix two compiler warnings in unit tests environment
Fix compiler warning and add missing includes in unit test environment
Aug 8, 2024
Opening PR up for review. |
Note for future self... try to remove |
Prusa-Firmware/tests/../Firmware/util.h:114:25: error: invalid conversion from ‘const char*’ to ‘char*’ [-fpermissive] 114 | pStrEnd = strchr(this->ptr, '"'); | ~~~~~~^~~~~~~~~~~~~~~~ | | | const char*
The following error is raised in unit testing environment: Prusa-Firmware/Firmware/Configuration.h:16:14: error: ‘uint16_t’ does not name a type 16 | extern const uint16_t _nPrinterType;
Fixes compiler warning in test environment: Prusa-Firmware/Firmware/eeprom.h:712:51: error: ‘size_t’ has not been declared 712 | bool eeprom_is_initialized_block(const void *__p, size_t __n); |
The file is calling eeprom_read_byte and should include avr/eeprom.h
Place system includes on top
gudnimg
force-pushed
the
minor-fixes-for-future-tests
branch
from
August 9, 2024 14:57
826ddbf
to
0153eb0
Compare
We should only be including it where needed
Only include it where needed
3d-gussner
approved these changes
Aug 20, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR fixes a few issues I noticed when attempting to create unit test for printer model checks in
util.cpp/h
.