Merge pull request #4970 from jclab-joseph/pr/fix/build-alpine_2.x

Backport 2.x: Fix test code to can be built on alpine #4969