Added exists check, test failing currently

Test cases currently fail