MEDIEVAL PIG BREEDERS found that the problem with selling piglets at market was that the little tykes would run about all over the place. To stop them making their escape, they would put them in a bag, known as a poke. (A small poke is to this day called a pocket.)
The more unscrupulous breeders would replace high-value piglets with cats, which were plentiful and of no practical use to either buyer or seller. It was, therefore, incumbent on the seller to check before handing over their cash.
The only way to make sure you weren’t being cheated when buying a pig in a poke was to let the cat out of the bag.