brightbit/frisby — Issue #3: Direct Testing of Integers, Booleans, and other object types
Author: ericboehs
Created: 2012-01-09 23:38:13+00:00
State: open

I'd like to test one of the elements in an array.

For example, given this JSON response ```{ data: [1, 2, 3, 4, 5] }```, I'd like to test that the returned array contains the number ```1```.

I'd imagine I'd use something like ```expectJSON('data.?', 1)``` or ```expectJSON('data.0', 1)``` to test this but I get a ```TypeError: Expected 'data.0' to be object or array (got 'number' from JSON response)```

Thanks!