A man faces a maximum sentence of a decade behind bars after allegedly punching holes through both windows of a parked police car with a rock.