If you really want to be sure your dog responds appropriately to invisible fence, it is essential to "proof" it properly. After you have thoroughly conditioned the animal to the fence, you need to use very high value distractions or lures while you are present (but not visible) to observe behavior. It's the only way to be reasonably sure your dog will not bolt through the fence, and then you still have the problem of other dogs or people possibly trespassing and causing a problem, since there is nothing to keep them out.
In the country, invisible fence can work well, although there is still the chance that the dog will learn to run through it. My friend uses it at her farm, and one of her three dogs (not Basenjis) will go through the fence if the temptation is strong enough.