tests: fix dname tests (clang analyzer)