[tests] Add tests to exercise various code paths in Select.replace()
The original patch for bug #1190458 broke tests in CubicWeb. The patch
has now been amended to fix the broken paths (namely, replacing the 'in'
tests with appropriate 'is_equivalent' loops).
These tests are adapted from CubicWeb's own test suite, especially those
that test FTIRANK() on sqlite (the function exists but is replaced by a
no-op).
\.pyc$
build/
rql_solve.so$
\.pytest\.restart$