Correct and improve cli test