Hey there, you can always restart your IT career, it's not pretty difficult for you since you have development experience of 6.5 years.
Automation Testing has taken the world by storm and selenium is among the most demanded tool these days. A large number of IT employers look for skilled employees who are well versed with tools like Selenium.
I guess you have made the right choice as per the current IT trends. You should go ahead in your pursuit of leaning automation testing.
It will definitely help you restart your career in IT.
All the best :)