3 ms·
That happens all the time. I generally encapsulate the logic compensating for the bug and decorate it with copious comments explaining the rational then write
by cptskippy 9y ago
That happens all the time. I generally encapsulate the logic compensating for the bug and decorate it with copious comments explaining the rational then write a unit test explicitly testing for the buggy behavior. If the bug gets fixed then the test fails and the product doesn't ship until it's resolved.
Yes I write unit tests for 3rd party APIs and libraries I consume if they show themselves to be inconsistent or buggy.
We actually use a 3rd party API that crashes regularly and we have a suite of unit tests surrounding it so when reports come in we can isolate, reproduce, and verify the problem before bringing fury down upon the vendor.
It is also handy during pre and post deployment validation to ensure that the environment your update is working in is 100% functional. I've rolled back releases before because an external resource had an unreported outage that caused our deployment validation to fail. With pre/post test you can test the environment before you even start.
- ramses0 9y agos/unit tests for 3rd party APIs/ => /acceptance tests for 3rd party APIs/
- 0xcde4c3db 9y agoThose are all fine things to do if you can afford them. In my case, I'm talking about bugs that come sturdily packaged in a $5000+ chassis sitting on a private VLAN in somebody else's building. So it goes.