Skip to content

Commit

Permalink
testsuite: t0007-ping.t: do not assume short hostnames
Browse files Browse the repository at this point in the history
Problem: A couple tests in `t0007-ping.t` assume short hostnames
by using $(hostname -s) as an expected value. This causes failures
when the domain is part of the hostname.

Change uses of $(hostname -s) to just $(hostname)

Fixes #4109
  • Loading branch information
grondo committed Mar 29, 2022
1 parent 4d01f7b commit 7ff9490
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions t/t0007-ping.t
Original file line number Diff line number Diff line change
Expand Up @@ -138,10 +138,10 @@ test_expect_success 'ping help output works' '
'

test_expect_success 'ping works with hostname' '
flux ping --count=1 $(hostname -s)
flux ping --count=1 $(hostname)
'
test_expect_success 'ping works with hostname!service' '
flux ping --count=1 "$(hostname -s)!broker"
flux ping --count=1 "$(hostname)!broker"
'
test_expect_success 'ping fails with unknown hostname' '
test_must_fail flux ping --count=1 "notmyhost!broker"
Expand Down

0 comments on commit 7ff9490

Please sign in to comment.