You asked for "maximum variations" so there can be only one valid answer, you won't get the maximum in fewer years, so the only valid answer is 5 years, making your Poll pointless.
Rather than using more years you can also use more instruments. instead of just using EURUSD also test with USDJPY, EURJPY, EURGBP, GBPJPY, etc.
Obviously if you can pass 8-10 years, then your EA will be probably more solid.
Optimized ? You don't talk about optimization yet, it's another matter.
Anyway I only give my opinion, you have to find your way yourself.