These tests are an opportunity to see if you do have the skills and abilities you would need if you get the job. If you fail, you can move on to your next job application. That’s far better than being given a role you are unsuited to and wasting time in a job you dislike.