Backport of 0ed7d155635da9f79d4dd67e4889087d3673c6da from master
Added proxy_models tests by Harm Geerts <github@geertswei.nl>.