If you can't look at the code, you need to trust interfaces to specify (and constrain) the implementation. The implementation needs to implement the entire interface and can't do anything not in the interface.
Otherwise, you're going to get bit by the Law of Leaky Abstractions.
The number of times I've been bit by systems not adhering to interfaces? Yeah, that's pretty frequent.
For example (from personal experience), the interface allows for race conditions, it's obvious they can happen (distributed systems), but the implementation didn't allow them, resulting in fun times.
Comments
If you can't look at the code, you need to trust interfaces to specify (and constrain) the implementation. The implementation needs to implement the entire interface and can't do anything not in the interface.
Otherwise, you're going to get bit by the Law of Leaky Abstractions.
The number of times I've been bit by systems not adhering to interfaces? Yeah, that's pretty frequent.
For example (from personal experience), the interface allows for race conditions, it's obvious they can happen (distributed systems), but the implementation didn't allow them, resulting in fun times.