News for hackers. Stuff that matters.
Re:How deep are your unit tests? by meaty on Monday December 10, 2012 @11:17AM (#4899697)
That's vertical decoupling.

Well the point of the abstraction is that you don't care about the contents, hence the term "black box abstraction".

It doesn't matter to the interface consumer what the implementation is, just that it does what the interface says it will do.

Our VFS layer has various backends which can be picked based on the client's requirements and this covers REST APIs, RDBMS and filesystems. There are various depths of stacks and abstractions hiding behind all that but to the consumer, it doesn't matter.

If it blows up anywhere in the stack, we can throw 80 levels of stack right down to the container thread if need be, but we only care about the abstraction at the point of failure.

Re:How deep are your unit tests? by jiggy2011 on Monday December 10, 2012 @11:26AM (#4899761)
True, if all of your classes can conform to the same interface.

When you integrate some third party black box with a different interface you're probably going to have to write at least one wrapper class.

Re:How deep are your unit tests? by meaty on Monday December 10, 2012 @11:41AM (#4899871)
True also. We wrap Amazon S3's client behind our VFS layer.