dpkg call fails on RHEL

Replace dpkg-based test with platform-independent test.

Closes-Bug: #1340164