Add py.test support

Note: this doesn't work in all cases yet, so I'm leaving `tangled test`
for now.