Add set credential testing code