Tests: Add assumption to restrict upgrade test from running against
invalid backcompat versions.
Throw parsing exception if terms filter or query has more than one field

Closes #5014