[FIX][TEST] Add test for SearchRequestBuilder.toString

Test that asserts that SearchRequestBuilder.toString doesn't mutate the search request.

See #7317