Skip to content

Fixed error when running BufferLogger UT as root - #5354

Merged
thomas-bc merged 6 commits into
nasa:develfrom
bevinduckett:buf-logger-ut-fix
Jul 8, 2026
Merged

thomas-bc merged 6 commits into
nasa:develfrom
bevinduckett:buf-logger-ut-fix

Conversation

@bevinduckett

Copy link
Copy Markdown
Collaborator
Related Issue(s) none
Has Unit Tests (y/n) yes
Documentation Included (y/n) n/a
Generative AI was used in this contribution (y/n) Yes

Change Description

Updated the BufferLogger unit test to skip LogFileValidation when run as root (not uncommon when running inside a container)

Rationale

Done because in UNIX root skips file read/write permission checks.

Testing/Review Recommendations

Verify BufferLogger UT still compiles for all targeted OSs & passes when executed as root (I verified in my dev container)

Future Work

N/A

AI Usage (see policy)

Used Google to lookup how to skip a test case & the macros for detecting unix systems

@LeStarch

LeStarch commented Jul 7, 2026

Copy link
Copy Markdown
Collaborator

@bevinduckett seems like there are multiple merge conflicts here.

Also, instead of defining a helper flag (UNISTD_INCLUDEDED) I'd recommend we just repeat the same #if check in both places. That way you don't have to find the first one, read that it defined a new flag, and then find again to pickup the second.

@LeStarch

LeStarch commented Jul 7, 2026

Copy link
Copy Markdown
Collaborator

@bevinduckett let me know if you'd like help resolving the above!

@bevinduckett

Copy link
Copy Markdown
Collaborator Author

Hi @LeStarch , it should be fixed. Can you kick off the jobs?

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

Coverage report — base devel

Overall (line): 81.40% → 81.40% (+0.00)
Regression threshold: 0.50% (line).

Regressions

(none over threshold)

Modules changed

Module Line Δ Function Δ Branch Δ
Fw/DataStructures 98.48 +0.18 97.14 +0.00 83.21 +0.18

Modules without UTs

CFDP/Checksum/GTest, Drv/ByteStreamDriverModel, Drv/Interfaces, Drv/LinuxGpioDriver, Drv/LinuxI2cDriver, Drv/LinuxSpiDriver, Drv/LinuxUartDriver, Drv/Ports, Drv/Ports/DataTypes, FppTestProject/FppTest/interfaces, FppTestProject/FppTest/topology/async, FppTestProject/FppTest/topology/components/Comp, FppTestProject/FppTest/topology/components/Framework, FppTestProject/FppTest/topology/components/Receiver, FppTestProject/FppTest/topology/components/Sender, FppTestProject/FppTest/topology/guarded, FppTestProject/FppTest/topology/ports, FppTestProject/FppTest/topology/sync, FppTestProject/FppTest/topology/top_ports, FppTestProject/FppTest/topology/types, Fw/Cmd, Fw/Com, Fw/Comp, Fw/FilePacket/GTest, Fw/Fpy, Fw/Interfaces, Fw/Obj, Fw/Port, Fw/Ports/CompletionStatus, Fw/Ports/Ready, Fw/Ports/Signal, Fw/Ports/SuccessCondition, Fw/Prm, Fw/SerializableFile/test/TestSerializable, Fw/Sm, Fw/Test, Fw/Types/GTest, Os/Models, Svc/Cycle, Svc/DpPorts, Svc/Fatal, Svc/FatalHandler, Svc/FileDownlinkPorts, Svc/FprimeProtocol, Svc/Interfaces, Svc/PassiveConsoleTextLogger, Svc/Ping, Svc/PolyIf, Svc/Ports/CommsPorts, Svc/Ports/FilePorts, Svc/Ports/OsTimeEpoch, Svc/Ports/TlmPacketizerPorts, Svc/Ports/VersionPorts, Svc/Sched, Svc/Seq, Svc/Subtopologies/CdhCore, Svc/Subtopologies/ComCcsds, Svc/Subtopologies/ComFprime, Svc/Subtopologies/ComLoggerTee, Svc/Subtopologies/DataProducts, Svc/Subtopologies/FileHandling, Svc/Types/TlmPacketizerTypes, Svc/WatchDog, TestDeploymentsProject/Ref/PingReceiver, TestDeploymentsProject/Ref/RecvBuffApp, TestDeploymentsProject/Ref/SendBuffApp, TestDeploymentsProject/Ref/Top, TestDeploymentsProject/Ref/TypeDemo, cmake/test/data/TestDeployment/TestBuildAutocoder, cmake/test/data/TestDeployment/TestChainedAutocoder, cmake/test/data/TestDeployment/TestHeaderAutocoder, cmake/test/data/TestDeployment/TestTargetAutocoder, cmake/test/data/test-fprime-library/TestLibrary/TestComponent, cmake/test/data/test-fprime-library2/TestLibrary2/TestComponent

@thomas-bc
thomas-bc merged commit 756fc71 into nasa:devel Jul 8, 2026
74 of 76 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.

3 participants