add ios category and fix device test bug