make better testing if function doesnt exist