The PCIe slots are backwards and forward compatible, meaning you can plug your 4.0 card into a 2.0 slot. It's just that your card won't be able to run at "full speed" in that slot so don't expect to be able to do any performance tests.
But, if you just want to see if the card works at all it should be no problem for that purpose.