test for error fn
trigger camera on event and setup preview element