Skip to content

tombstone-e2e: use POSIX shell for portability#347

Closed
kev009 wants to merge 1 commit into
InterNetNews:mainfrom
kev009:expire-tombstone-e2e
Closed

tombstone-e2e: use POSIX shell for portability#347
kev009 wants to merge 1 commit into
InterNetNews:mainfrom
kev009:expire-tombstone-e2e

Conversation

@kev009

@kev009 kev009 commented Jun 14, 2026

Copy link
Copy Markdown
Contributor

The test relied on GNU-style options unavailable on AIX and Solaris native tools: grep -F, sed -i, and a \t escape in a sed character class

Replace them with POSIX-only helpers so the test runs without requiring GNU tools or innshellvars detection:

  • contains(): a while-read/case substring matcher (no grep -F)
  • countlines(): wc -l | tr -cd '0-9' (no sed, handles AIX wc leading whitespace)
  • setconf(): sed > tmp && mv (no sed -i)

Fixes #345.

The test relied on GNU-style options unavailable on AIX and Solaris
native tools: grep -F, sed -i, and a \t escape in a sed character class

Replace them with POSIX-only helpers so the test runs
without requiring GNU tools or innshellvars detection:

  - contains(): a while-read/case substring matcher (no grep -F)
  - countlines(): wc -l | tr -cd '0-9' (no sed, handles AIX wc
    leading whitespace)
  - setconf(): sed > tmp && mv (no sed -i)

Fixes InterNetNews#345.
@Julien-Elie

Copy link
Copy Markdown
Contributor

Many thanks for having taken the time to look at this and improve the portability.

@Julien-Elie Julien-Elie self-assigned this Jun 19, 2026
@Julien-Elie Julien-Elie added bug Something isn't working P: low Low priority C: test suite Related to the test suite labels Jun 19, 2026
@Julien-Elie Julien-Elie added this to the 2.7.4 milestone Jun 19, 2026
Julien-Elie pushed a commit that referenced this pull request Jun 19, 2026
The test relied on GNU-style options unavailable on AIX and Solaris
native tools: grep -F, sed -i, and a \t escape in a sed character
class.

Replace them with POSIX-only helpers so the test runs
without requiring GNU tools or innshellvars detection:

  - contains(): a while-read/case substring matcher (no grep -F)
  - countlines(): wc -l | tr -cd '0-9' (no sed, handles AIX wc
    leading whitespace)
  - setconf(): sed > tmp && mv (no sed -i)

Fixes #345.
Closes #347.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working C: test suite Related to the test suite P: low Low priority

Development

Successfully merging this pull request may close these issues.

Portability of expire/tombstone-e2e test

2 participants