test_slice now checks shape of trace rather than size