diff options
| author | Nguyễn Gia Phong <cnx@loang.net> | 2025-12-19 10:13:50 +0900 |
|---|---|---|
| committer | Ludovic Courtès <ludo@gnu.org> | 2026-01-09 15:22:45 +0100 |
| commit | 211ee32c95ed81e0e16dc8968157aec21a44e7e6 (patch) | |
| tree | c9d871ab5950f5ae5b6338e5022429acca930959 /gnu | |
| parent | d7ad785c6d6b02f711c1595a7b8ce6d023d0e547 (diff) | |
tests: %test-nss-mdns: Fix test order.
Before this, the test failed because Avahi CLI utilities
exit with a non-zero status in case of a cache miss
(instead of blocking?).
* gnu/tests/avahi.scm (run-nss-mdns-test): Move the Avahi CLI tests
after other name resolution tests.
Change-Id: I88ab03abf39cf24ee2ce763c719444ac65504cc2
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Merges: #4955
Diffstat (limited to 'gnu')
| -rw-r--r-- | gnu/tests/avahi.scm | 27 |
1 files changed, 13 insertions, 14 deletions
diff --git a/gnu/tests/avahi.scm b/gnu/tests/avahi.scm index 32310321247..d7f2fdaa72d 100644 --- a/gnu/tests/avahi.scm +++ b/gnu/tests/avahi.scm | |||
| @@ -132,20 +132,6 @@ | |||
| 132 | (start-service 'networking)) | 132 | (start-service 'networking)) |
| 133 | marionette)) | 133 | marionette)) |
| 134 | 134 | ||
| 135 | (test-equal "avahi-resolve-host-name" | ||
| 136 | 0 | ||
| 137 | (marionette-eval | ||
| 138 | '(system* | ||
| 139 | "/run/current-system/profile/bin/avahi-resolve-host-name" | ||
| 140 | "-v" #$mdns-host-name) | ||
| 141 | marionette)) | ||
| 142 | |||
| 143 | (test-equal "avahi-browse" | ||
| 144 | 0 | ||
| 145 | (marionette-eval | ||
| 146 | '(system* "/run/current-system/profile/bin/avahi-browse" "-avt") | ||
| 147 | marionette)) | ||
| 148 | |||
| 149 | (test-assert "getaddrinfo .local" | 135 | (test-assert "getaddrinfo .local" |
| 150 | ;; Wait for the 'avahi-daemon' service and perform a resolution. | 136 | ;; Wait for the 'avahi-daemon' service and perform a resolution. |
| 151 | (match (marionette-eval | 137 | (match (marionette-eval |
| @@ -168,6 +154,19 @@ | |||
| 168 | (and (string=? (hostent:name result) #$mdns-host-name) | 154 | (and (string=? (hostent:name result) #$mdns-host-name) |
| 169 | (= (hostent:addrtype result) AF_INET))))) | 155 | (= (hostent:addrtype result) AF_INET))))) |
| 170 | 156 | ||
| 157 | (test-equal "avahi-resolve host name" | ||
| 158 | 0 | ||
| 159 | (marionette-eval | ||
| 160 | '(system* "/run/current-system/profile/bin/avahi-resolve" | ||
| 161 | "--verbose" "--name" #$mdns-host-name) | ||
| 162 | marionette)) | ||
| 163 | |||
| 164 | (test-equal "avahi-browse" | ||
| 165 | 0 | ||
| 166 | (marionette-eval | ||
| 167 | '(system* "/run/current-system/profile/bin/avahi-browse" | ||
| 168 | "--all" "--verbose" "--terminate") | ||
| 169 | marionette)) | ||
| 171 | 170 | ||
| 172 | (test-end)))) | 171 | (test-end)))) |
| 173 | 172 | ||
