Skip to content

Truncate assert path#5141

Open
bevinduckett wants to merge 6 commits into
nasa:develfrom
bevinduckett:truncate-assert-path
Open

Truncate assert path#5141
bevinduckett wants to merge 6 commits into
nasa:develfrom
bevinduckett:truncate-assert-path

Conversation

@bevinduckett
Copy link
Copy Markdown
Contributor

@bevinduckett bevinduckett commented May 12, 2026

Related Issue(s) #5122
Has Unit Tests (y/n) y
Documentation Included (y/n) n
Generative AI was used in this contribution (y/n) y

Change Description

  1. Added the file path leading-truncation for the log() message from reportAssert() and added unit test coverage.
  2. Updated the truncation for the file path from the event argument to be leading-truncation (not trailing truncation)
  3. Added custom config to the unit test so that file path truncation would be tested (custom configuration)
  4. Updated the default value for AssertFatalAdapterEventFileSize to be significantly less than the default value for FwAssertTextSize

Rationale

See feature rationale in #5122

Testing/Review Recommendations

Future Work

We could consider adding a function to StringUtils to do leading-truncation

AI Usage (see policy)

AI (Claude code, Sonnet 4.5) was used to assist with the unit test updates

bevinduckett and others added 4 commits May 11, 2026 18:40
Added the file path leading-truncation for the log() message from reportAssert() and added unit test coverage.
Updated the truncation for the file path from the event argument to be leading-truncation (not trailing truncation)
Added custom config to the unit test so that file path truncation would be tested (custom configuration)
@bevinduckett bevinduckett marked this pull request as draft May 12, 2026 02:19
Removed the config override that was being done for the AssertFatalAdaptor UT and instead updated AssertFatalAdapterEventFileSize  in default/config
@bevinduckett bevinduckett marked this pull request as ready for review May 12, 2026 02:32
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.

1 participant