zscanner-test: improve test script

Change-Id: Ic122d9fb46c97946bb35fd83f4fae9e810257e5d