Supports js_pairs on function objects. See #337

This counts—output being

```
1..1
ok
```

Or failing with a non-zero exit code. I didn't want to expand on this test too much because it relies on the `name` property of Function being non-enumerable, which isn't really the case (it's a getter), so should be properly implemented and then tested.