Use Custom Permissions To Bypass Validation Rules And Pass Unit Tests

Picture this… it’s already 9pm on deployment night (Friday night of course). You’ve pushed to three environments already and spent at least three hours resolving unit test failures. If all your tests pass this time, you can go home and enjoy a well deserved hot cocoa….

THEN THIS HAPPENS:

Unit Tests Fail

FIELD_CUSTOM_VALIDATION_EXCEPTION

Someone else deployed a Validation Rule that is causing almost half your unit tests to fail, effectively ruining your weekend and destroying all your dreams. Has this ever happened to you? Well you’re not alone…

Continue reading →