The problem is that I was logging the test user by using the Settings --> iTunes & App Store --> Apple ID.
This process seems to "convert" the test user into a "real user". In fact, you get asked for credit card info and such, as would be expected for a "real user".
The solution is:
- create a new test user
- ensure that no user is logged in the Settings --> iTunes & App Store --> Apple ID
- test the purchase path in your app
- when asked for user credentials, use the newly created user credentials
I hope this saves you time.